summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorin2 <in2@63ad8ddf-47c3-0310-b6dd-a9e9d9715204>2002-07-03 03:17:31 +0800
committerin2 <in2@63ad8ddf-47c3-0310-b6dd-a9e9d9715204>2002-07-03 03:17:31 +0800
commit32633f53d27446544fcf296c16c5b1c2bfe6625a (patch)
tree59655c4d0672fcd87bf31e702a285ed3dcc4531b
parent0fc1088b726b2f0e5bb5ee0799f58002e7aec9f3 (diff)
downloadpttbbs-32633f53d27446544fcf296c16c5b1c2bfe6625a.tar
pttbbs-32633f53d27446544fcf296c16c5b1c2bfe6625a.tar.gz
pttbbs-32633f53d27446544fcf296c16c5b1c2bfe6625a.tar.bz2
pttbbs-32633f53d27446544fcf296c16c5b1c2bfe6625a.tar.lz
pttbbs-32633f53d27446544fcf296c16c5b1c2bfe6625a.tar.xz
pttbbs-32633f53d27446544fcf296c16c5b1c2bfe6625a.tar.zst
pttbbs-32633f53d27446544fcf296c16c5b1c2bfe6625a.zip
do NOT reload memory if shared-memoy fails
git-svn-id: http://opensvn.csie.org/pttbbs/pttbbs/trunk@407 63ad8ddf-47c3-0310-b6dd-a9e9d9715204
-rw-r--r--pttbbs/mbbsd/passwd.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/pttbbs/mbbsd/passwd.c b/pttbbs/mbbsd/passwd.c
index 7e877ac4..4291fa3e 100644
--- a/pttbbs/mbbsd/passwd.c
+++ b/pttbbs/mbbsd/passwd.c
@@ -1,4 +1,4 @@
-/* $Id: passwd.c,v 1.4 2002/07/02 18:54:28 in2 Exp $ */
+/* $Id: passwd.c,v 1.5 2002/07/02 19:17:31 in2 Exp $ */
#include "bbs.h"
static int semid = -1;
@@ -51,7 +51,8 @@ int passwd_update_money(int num) {
if(num < 1 || num > MAX_USERS)
return -1;
passwd_query(num, &user);
- user.money = moneyof(num);
+ if( SHM->loaded )
+ user.money = moneyof(num);
passwd_update(num, &user);
return 0;
}