summaryrefslogtreecommitdiffstats
path: root/mbbsd/edit.c
diff options
context:
space:
mode:
authorkcwu <kcwu@63ad8ddf-47c3-0310-b6dd-a9e9d9715204>2003-06-28 16:47:45 +0800
committerkcwu <kcwu@63ad8ddf-47c3-0310-b6dd-a9e9d9715204>2003-06-28 16:47:45 +0800
commit2dea9dc6eeee3dcd9a0ebc32dcee9723c4787c91 (patch)
tree87e9a623c3a4426e104f87511e2b66f86f75a829 /mbbsd/edit.c
parentc5f8b96c358e673945943d92c4ba562eba1f96ec (diff)
downloadpttbbs-2dea9dc6eeee3dcd9a0ebc32dcee9723c4787c91.tar
pttbbs-2dea9dc6eeee3dcd9a0ebc32dcee9723c4787c91.tar.gz
pttbbs-2dea9dc6eeee3dcd9a0ebc32dcee9723c4787c91.tar.bz2
pttbbs-2dea9dc6eeee3dcd9a0ebc32dcee9723c4787c91.tar.lz
pttbbs-2dea9dc6eeee3dcd9a0ebc32dcee9723c4787c91.tar.xz
pttbbs-2dea9dc6eeee3dcd9a0ebc32dcee9723c4787c91.tar.zst
pttbbs-2dea9dc6eeee3dcd9a0ebc32dcee9723c4787c91.zip
assert() the return value of strchr() strrchr()
git-svn-id: http://opensvn.csie.org/pttbbs/pttbbs/trunk/pttbbs@982 63ad8ddf-47c3-0310-b6dd-a9e9d9715204
Diffstat (limited to 'mbbsd/edit.c')
-rw-r--r--mbbsd/edit.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/mbbsd/edit.c b/mbbsd/edit.c
index 738cb4f8..c3e2fdc5 100644
--- a/mbbsd/edit.c
+++ b/mbbsd/edit.c
@@ -1,4 +1,4 @@
-/* $Id: edit.c,v 1.35 2003/06/25 22:56:19 kcwu Exp $ */
+/* $Id: edit.c,v 1.36 2003/06/28 08:47:45 kcwu Exp $ */
/* edit.c, 用來提供 bbs上的文字編輯器, 即 ve.
* 現在這一個是惡搞過的版本, 比較不穩定, 用比較多的 cpu, 但是可以省下許多
* 的記憶體 (以 Ptt為例, 在九千人上站的時候, 約可省下 50MB 的記憶體)
@@ -700,6 +700,7 @@ do_quote()
if ((curredit & EDIT_BOTH) && (str = strchr(quote_user, '.'))) {
strcpy(++str, ptr);
str = strchr(str, ' ');
+ assert(str);
str[0] = '\0';
}
} else