diff options
author | kcwu <kcwu@63ad8ddf-47c3-0310-b6dd-a9e9d9715204> | 2006-09-17 21:45:05 +0800 |
---|---|---|
committer | kcwu <kcwu@63ad8ddf-47c3-0310-b6dd-a9e9d9715204> | 2006-09-17 21:45:05 +0800 |
commit | 271f41f585830f658957bc9a485869ff02158875 (patch) | |
tree | a34faf0c573f0336109c666a95b3ac691b800bbd | |
parent | 8f26219156d6ac6f0eaf26f5f3fadf81e16c9f18 (diff) | |
download | pttbbs-271f41f585830f658957bc9a485869ff02158875.tar pttbbs-271f41f585830f658957bc9a485869ff02158875.tar.gz pttbbs-271f41f585830f658957bc9a485869ff02158875.tar.bz2 pttbbs-271f41f585830f658957bc9a485869ff02158875.tar.lz pttbbs-271f41f585830f658957bc9a485869ff02158875.tar.xz pttbbs-271f41f585830f658957bc9a485869ff02158875.tar.zst pttbbs-271f41f585830f658957bc9a485869ff02158875.zip |
code revise.
git-svn-id: http://opensvn.csie.org/pttbbs/trunk/pttbbs@3425 63ad8ddf-47c3-0310-b6dd-a9e9d9715204
-rw-r--r-- | mbbsd/fav.c | 7 |
1 files changed, 1 insertions, 6 deletions
diff --git a/mbbsd/fav.c b/mbbsd/fav.c index 83846ff5..163459cd 100644 --- a/mbbsd/fav.c +++ b/mbbsd/fav.c @@ -569,13 +569,8 @@ int fav_save(void) fwrite(&version, sizeof(version), 1, fwp); write_favrec(fwp, fp); - fflush(fwp); - if (!ferror(fwp)) { - fclose(fwp); + if(fclose(fwp)==0) Rename(buf, buf2); - } - else - fclose(fwp); return 0; } |