summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorvictor <victor@63ad8ddf-47c3-0310-b6dd-a9e9d9715204>2007-03-23 20:15:10 +0800
committervictor <victor@63ad8ddf-47c3-0310-b6dd-a9e9d9715204>2007-03-23 20:15:10 +0800
commit8546759cec4d91a22da56ee261f6aac0d77abd5c (patch)
treebcb20e2e320a01ca3beaf3a68e11d5b5dcaa02a7
parent0f867492a82d71f8205f70e007dc196010437031 (diff)
downloadpttbbs-8546759cec4d91a22da56ee261f6aac0d77abd5c.tar
pttbbs-8546759cec4d91a22da56ee261f6aac0d77abd5c.tar.gz
pttbbs-8546759cec4d91a22da56ee261f6aac0d77abd5c.tar.bz2
pttbbs-8546759cec4d91a22da56ee261f6aac0d77abd5c.tar.lz
pttbbs-8546759cec4d91a22da56ee261f6aac0d77abd5c.tar.xz
pttbbs-8546759cec4d91a22da56ee261f6aac0d77abd5c.tar.zst
pttbbs-8546759cec4d91a22da56ee261f6aac0d77abd5c.zip
remove unused variables
git-svn-id: http://opensvn.csie.org/pttbbs/trunk/pttbbs@3489 63ad8ddf-47c3-0310-b6dd-a9e9d9715204
-rw-r--r--include/pttstruct.h5
-rw-r--r--mbbsd/cache.c9
2 files changed, 6 insertions, 8 deletions
diff --git a/include/pttstruct.h b/include/pttstruct.h
index 58ac0810..6e879f92 100644
--- a/include/pttstruct.h
+++ b/include/pttstruct.h
@@ -569,9 +569,10 @@ typedef struct {
char notes[MAX_MOVIE][256*11];
char gap_18[sizeof(int)];
char today_is[20];
- int n_notes[MAX_MOVIE_SECTION]; /* 一節中有幾個 看板 */
+ // FIXME remove never_used__n_notes & never_used__next_refresh
+ int never_used__n_notes[MAX_MOVIE_SECTION]; /* 一節中有幾個 看板 */
char gap_19[sizeof(int)];
- int next_refresh[MAX_MOVIE_SECTION]; /* 下一次要refresh的 看板 */
+ int never_used__next_refresh[MAX_MOVIE_SECTION]; /* 下一次要refresh的 看板 */
char gap_20[sizeof(int)];
msgque_t loginmsg; /* 進站水球 */
int max_film;
diff --git a/mbbsd/cache.c b/mbbsd/cache.c
index 465a59e0..45c21f06 100644
--- a/mbbsd/cache.c
+++ b/mbbsd/cache.c
@@ -849,7 +849,7 @@ reload_pttcache(void)
fileheader_t item, subitem;
char pbuf[256], buf[256], *chr;
FILE *fp, *fp1, *fp2;
- int id, section = 0;
+ int id;
SHM->Pbusystate = 1;
SHM->max_film = 0;
@@ -864,8 +864,6 @@ reload_pttcache(void)
pbuf, item.filename);
if (!(fp1 = fopen(buf, "r")))
continue;
- SHM->next_refresh[section] = SHM->n_notes[section] = id;
- section++;
while (fread(&subitem, sizeof(subitem), 1, fp1)) {
snprintf(buf, sizeof(buf),
"%s/%s/%s", pbuf, item.filename,
@@ -880,14 +878,13 @@ reload_pttcache(void)
break;
}
fclose(fp1);
- if (id >= MAX_MOVIE || section >= MAX_MOVIE_SECTION)
+ if (id >= MAX_MOVIE)
break;
}
}
fclose(fp);
}
- SHM->next_refresh[section] = -1;
- SHM->n_notes[section] = SHM->max_film = id - 1;
+ SHM->max_film = id - 1;
SHM->max_history = SHM->max_film - 2;
if (SHM->max_history > MAX_HISTORY - 1)
SHM->max_history = MAX_HISTORY - 1;