diff options
author | scw <scw@63ad8ddf-47c3-0310-b6dd-a9e9d9715204> | 2006-01-22 01:05:46 +0800 |
---|---|---|
committer | scw <scw@63ad8ddf-47c3-0310-b6dd-a9e9d9715204> | 2006-01-22 01:05:46 +0800 |
commit | 8212b34a8810a637cc6f0590183f34a2abc447ec (patch) | |
tree | a4deb4f9acdff1a10c0e536b0c607a53e617a8ee | |
parent | 2d06d410d63e0071fe3f7cc9e5be79b521478eab (diff) | |
download | pttbbs-8212b34a8810a637cc6f0590183f34a2abc447ec.tar pttbbs-8212b34a8810a637cc6f0590183f34a2abc447ec.tar.gz pttbbs-8212b34a8810a637cc6f0590183f34a2abc447ec.tar.bz2 pttbbs-8212b34a8810a637cc6f0590183f34a2abc447ec.tar.lz pttbbs-8212b34a8810a637cc6f0590183f34a2abc447ec.tar.xz pttbbs-8212b34a8810a637cc6f0590183f34a2abc447ec.tar.zst pttbbs-8212b34a8810a637cc6f0590183f34a2abc447ec.zip |
Fix r3267, board title disappear after setting boards
git-svn-id: http://opensvn.csie.org/pttbbs/trunk/pttbbs@3269 63ad8ddf-47c3-0310-b6dd-a9e9d9715204
-rw-r--r-- | mbbsd/admin.c | 36 |
1 files changed, 24 insertions, 12 deletions
diff --git a/mbbsd/admin.c b/mbbsd/admin.c index fa285709..50f135c8 100644 --- a/mbbsd/admin.c +++ b/mbbsd/admin.c @@ -589,12 +589,18 @@ m_mod_board(char *bname) move(1, 0); clrtobot(); } - if (newbh.brdattr & BRD_GROUPBOARD) - strcpy(newbh.title + 5, "Σ"); - else if (newbh.brdattr & BRD_NOTRAN) - strcpy(newbh.title + 5, "◎"); - else - strcpy(newbh.title + 5, "●"); + { + const char* brd_symbol; + if (newbh.brdattr & BRD_GROUPBOARD) + brd_symbol = "Σ"; + else if (newbh.brdattr & BRD_NOTRAN) + brd_symbol = "◎"; + else + brd_symbol = "●"; + + newbh.title[5] = brd_symbol[0]; + newbh.title[6] = brd_symbol[1]; + } if (HasUserPerm(PERM_SYSOP|PERM_BOARD) && !(newbh.brdattr & BRD_HIDE)) { getdata_str(14, 0, "設定讀寫權限(Y/N)?", ans, sizeof(ans), LCECHO, "N"); @@ -886,12 +892,18 @@ m_newbrd(int whatclass, int recover) newboard.brdattr &= ~BRD_CPLOG; } - if (newboard.brdattr & BRD_GROUPBOARD) - strcpy(newboard.title + 5, "Σ"); - else if (newboard.brdattr & BRD_NOTRAN) - strcpy(newboard.title + 5, "◎"); - else - strcpy(newboard.title + 5, "●"); + { + const char* brd_symbol; + if (newboard.brdattr & BRD_GROUPBOARD) + brd_symbol = "Σ"; + else if (newboard.brdattr & BRD_NOTRAN) + brd_symbol = "◎"; + else + brd_symbol = "●"; + + newboard.title[5] = brd_symbol[0]; + newboard.title[6] = brd_symbol[1]; + } newboard.level = 0; getdata(11, 0, "板主名單:", newboard.BM, sizeof(newboard.BM), DOECHO); |