diff options
author | victor <victor@63ad8ddf-47c3-0310-b6dd-a9e9d9715204> | 2003-10-14 21:38:09 +0800 |
---|---|---|
committer | victor <victor@63ad8ddf-47c3-0310-b6dd-a9e9d9715204> | 2003-10-14 21:38:09 +0800 |
commit | 416c211e7d2fb54bb2e1df432e01ac8772c1c763 (patch) | |
tree | a228ca785dd04cbfc7ac5f577dce74bd63f79c93 /util | |
parent | 994e44a546b9e0a7bfbbd3ee935a3882b780f2cc (diff) | |
download | pttbbs-416c211e7d2fb54bb2e1df432e01ac8772c1c763.tar pttbbs-416c211e7d2fb54bb2e1df432e01ac8772c1c763.tar.gz pttbbs-416c211e7d2fb54bb2e1df432e01ac8772c1c763.tar.bz2 pttbbs-416c211e7d2fb54bb2e1df432e01ac8772c1c763.tar.lz pttbbs-416c211e7d2fb54bb2e1df432e01ac8772c1c763.tar.xz pttbbs-416c211e7d2fb54bb2e1df432e01ac8772c1c763.tar.zst pttbbs-416c211e7d2fb54bb2e1df432e01ac8772c1c763.zip |
fix cleanshm, add to Makefile (but not in default entry)
git-svn-id: http://opensvn.csie.org/pttbbs/trunk/pttbbs@1242 63ad8ddf-47c3-0310-b6dd-a9e9d9715204
Diffstat (limited to 'util')
-rw-r--r-- | util/Makefile | 2 | ||||
-rw-r--r-- | util/cleanshm.c | 3 |
2 files changed, 4 insertions, 1 deletions
diff --git a/util/Makefile b/util/Makefile index b4788abd..a3931ca6 100644 --- a/util/Makefile +++ b/util/Makefile @@ -85,3 +85,5 @@ installbbsctl: bbsctl chown root /home/bbs/bin/bbsctl chmod 4755 /home/bbs/bin/bbsctl +cleanshm: cleanshm.c ${UTIL_OBJS} + ${CC} ${CFLAGS} ${LDFLAGS} -o ${fn} ${UTIL_OBJS} cleanshm.c diff --git a/util/cleanshm.c b/util/cleanshm.c index 37eb4018..3632ad5e 100644 --- a/util/cleanshm.c +++ b/util/cleanshm.c @@ -11,7 +11,8 @@ int clean_unused_var(userec_t *rec) rec->badpost = 0; rec->goodsale = 0; rec->badsale = 0; - memset(pad, 0, sizeof(pad)); + memset(rec->pad, 0, sizeof(rec->pad)); + return 0; } int main(int argc, char *argv[]) |