From 9ff5fd166d3a7fdcec3552e61bc84ba29b5e26c2 Mon Sep 17 00:00:00 2001 From: in2 Date: Sat, 26 Oct 2002 03:54:15 +0000 Subject: MAX_EDIT_LINE git-svn-id: http://opensvn.csie.org/pttbbs/pttbbs/trunk/pttbbs@542 63ad8ddf-47c3-0310-b6dd-a9e9d9715204 --- mbbsd/edit.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'mbbsd') diff --git a/mbbsd/edit.c b/mbbsd/edit.c index 5073d10a..8685dfc5 100644 --- a/mbbsd/edit.c +++ b/mbbsd/edit.c @@ -1,4 +1,4 @@ -/* $Id: edit.c,v 1.19 2002/09/11 07:16:49 kcwu Exp $ */ +/* $Id: edit.c,v 1.20 2002/10/26 03:54:15 in2 Exp $ */ #include "bbs.h" typedef struct textline_t { struct textline_t *prev; @@ -268,6 +268,12 @@ split(textline_t * line, int pos) register char *ptr; int spcs = indent_spcs(); +#ifdef MAX_EDIT_LINE + if( totaln == MAX_EDIT_LINE ){ + vmsg("MAX_EDIT_LINE exceed"); + return; + } +#endif totaln++; p->len = line->len - pos + spcs; -- cgit v1.2.3