Made some bug fixes final
This commit is contained in:
parent
dea60eb245
commit
1c8e9f2769
11
ChangeLog
11
ChangeLog
@ -1,10 +1,5 @@
|
||||
$Id$
|
||||
|
||||
WARNING: Extra debug logging enabled for checking internet news dupes.
|
||||
This will just make bigger logfiles if you gate news.
|
||||
Since 28-08-2002 mbfido news produces real big logs!!
|
||||
Extra debug logging will be removed around 14 Oct 2002.
|
||||
|
||||
|
||||
MBSEBBS History.
|
||||
|
||||
@ -36,6 +31,8 @@ v0.35.04 29-Sep-2002
|
||||
Files and echomail security flags implemented.
|
||||
Echomail rescan will also work with newsgroups.
|
||||
Removed some debug logging with files replace.
|
||||
Fixed trashing news dupes file when mbfido was called multiple
|
||||
times. Improved program locking.
|
||||
|
||||
mbsetup:
|
||||
Added setup for the nodes record for security flags.
|
||||
@ -44,6 +41,10 @@ v0.35.04 29-Sep-2002
|
||||
Added setup for the tic areas security flags.
|
||||
Added setup for the message areas security flags.
|
||||
Menu 14, edit files database had the wrong selection prompt.
|
||||
Fixed backspace/delete key issue.
|
||||
|
||||
mbmon:
|
||||
Fixed backspace/delete key issue.
|
||||
|
||||
mbindex:
|
||||
Removed debug logging.
|
||||
|
5
TODO
5
TODO
@ -79,7 +79,7 @@ mbfido:
|
||||
|
||||
L: Add %from command to areamgr/filemgr.
|
||||
|
||||
N: Add areas security with flags.
|
||||
L: Add netmail notification of changed areas.
|
||||
|
||||
mbcico:
|
||||
L: Implement modem connect response translation for ISDN lines, i.e.
|
||||
@ -158,6 +158,3 @@ mbsetup:
|
||||
Fileecho groups <=> Newfile reports
|
||||
Fileecho groups <=> BBS Areas
|
||||
|
||||
N: Add backspace test and store result in global setup.
|
||||
Note: experimental patch to test Rubout key as backspace.
|
||||
|
||||
|
21
lib/dbdupe.c
21
lib/dbdupe.c
@ -1,6 +1,6 @@
|
||||
/*****************************************************************************
|
||||
*
|
||||
* %Id$
|
||||
* $Id$
|
||||
* Purpose ...............: Dupe checking.
|
||||
*
|
||||
*****************************************************************************
|
||||
@ -56,7 +56,7 @@ void InitDupes()
|
||||
{
|
||||
int i;
|
||||
|
||||
Syslog('n', "Init Dupes");
|
||||
Syslog('N', "Init Dupes");
|
||||
for (i = 0; i < 3; i++) {
|
||||
dupes[i].crcs= NULL;
|
||||
dupes[i].loaded = FALSE;
|
||||
@ -111,18 +111,18 @@ int CheckDupe(unsigned long crc, int idx, int max)
|
||||
dupes[idx].crcs[dupes[idx].count] = test;
|
||||
dupes[idx].count++;
|
||||
}
|
||||
Syslog('n', "Loaded %d dupe records in %s", dupes[idx].count++, files[idx]);
|
||||
Syslog('N', "Loaded %d dupe records in %s", dupes[idx].count++, files[idx]);
|
||||
fclose(fil);
|
||||
free(dfile);
|
||||
dupes[idx].loaded = TRUE;
|
||||
dupes[idx].max = max;
|
||||
}
|
||||
|
||||
Syslog('n', "dupetest %08x %s %d", crc, files[idx], max);
|
||||
// Syslog('N', "dupetest %08x %s %d", crc, files[idx], max);
|
||||
|
||||
for (i = 0; i < dupes[idx].count; i++) {
|
||||
if (dupes[idx].crcs[i] == crc) {
|
||||
Syslog('n', "dupe at %d", i);
|
||||
// Syslog('N', "dupe at %d", i);
|
||||
return TRUE;
|
||||
}
|
||||
}
|
||||
@ -130,7 +130,7 @@ int CheckDupe(unsigned long crc, int idx, int max)
|
||||
* Not a dupe, append new crc value
|
||||
*/
|
||||
dupes[idx].crcs[dupes[idx].count] = crc;
|
||||
Syslog('n', "Added new dupe at %d", dupes[idx].count);
|
||||
// Syslog('N', "Added new dupe at %d", dupes[idx].count);
|
||||
dupes[idx].count++;
|
||||
dupes[idx].changed = TRUE;
|
||||
|
||||
@ -151,7 +151,7 @@ void CloseDdb(int idx)
|
||||
FILE *fil;
|
||||
|
||||
dfile = calloc(PATH_MAX, sizeof(char));
|
||||
Syslog('n', "Checking %s.dupe", files[idx]);
|
||||
// Syslog('N', "Checking %s.dupe", files[idx]);
|
||||
if (dupes[idx].loaded) {
|
||||
if (dupes[idx].changed) {
|
||||
if (dupes[idx].count > dupes[idx].max)
|
||||
@ -160,15 +160,13 @@ void CloseDdb(int idx)
|
||||
start = 0;
|
||||
sprintf(dfile, "%s/etc/%s.dupe", getenv("MBSE_ROOT"), files[idx]);
|
||||
if ((fil = fopen(dfile, "w"))) {
|
||||
Syslog('n', "Writing dupes %d to %d", start, dupes[idx].count);
|
||||
Syslog('N', "Writing dupes %d to %d", start, dupes[idx].count);
|
||||
for (j = start; j < dupes[idx].count; j++)
|
||||
fwrite(&dupes[idx].crcs[j], sizeof(unsigned long), 1, fil);
|
||||
fclose(fil);
|
||||
} else {
|
||||
WriteError("$Can't write %s", dfile);
|
||||
}
|
||||
} else {
|
||||
Syslog('n', "Not changed so not saved");
|
||||
}
|
||||
|
||||
dupes[idx].changed = FALSE;
|
||||
@ -179,8 +177,6 @@ void CloseDdb(int idx)
|
||||
free(dupes[idx].crcs);
|
||||
dupes[idx].crcs = NULL;
|
||||
|
||||
} else {
|
||||
Syslog('n', "Not loaded");
|
||||
}
|
||||
free(dfile);
|
||||
}
|
||||
@ -191,7 +187,6 @@ void CloseDupes()
|
||||
{
|
||||
int i;
|
||||
|
||||
Syslog('n', "Closing dupes databases");
|
||||
for (i = 0; i < 3; i++)
|
||||
CloseDdb(i);
|
||||
}
|
||||
|
@ -77,7 +77,6 @@ static int dirtyoutcode = CHRS_NOTSET;
|
||||
*/
|
||||
extern int do_quiet;
|
||||
extern int do_learn;
|
||||
extern int most_debug;
|
||||
extern int news_in;
|
||||
extern int email_in;
|
||||
extern char *replyaddr;
|
||||
|
@ -189,15 +189,12 @@ void ScanNews(void)
|
||||
struct msgareashdr Msgshdr;
|
||||
struct msgareas Msgs;
|
||||
|
||||
most_debug = TRUE;
|
||||
IsDoing((char *)"Scan News");
|
||||
if (nntp_connect() == -1) {
|
||||
WriteError("Can't connect to newsserver");
|
||||
most_debug = FALSE;
|
||||
return;
|
||||
}
|
||||
if (get_xoverview()) {
|
||||
most_debug = FALSE;
|
||||
return;
|
||||
}
|
||||
|
||||
@ -248,7 +245,6 @@ most_debug = FALSE;
|
||||
free(tmp);
|
||||
}
|
||||
do_flush = TRUE;
|
||||
most_debug = FALSE;
|
||||
if (!do_quiet)
|
||||
printf("\r \r");
|
||||
}
|
||||
@ -303,9 +299,9 @@ int do_one_group(List **art, char *grpname, char *ftntag, int maxarticles)
|
||||
/*
|
||||
* If the message isn't a dupe, it must be new for us.
|
||||
*/
|
||||
// most_debug = TRUE;
|
||||
most_debug = TRUE;
|
||||
get_article(tmp->msgid, ftntag);
|
||||
// most_debug = FALSE;
|
||||
most_debug = FALSE;
|
||||
fetched++;
|
||||
}
|
||||
}
|
||||
@ -519,7 +515,6 @@ int get_xoverview(void)
|
||||
}
|
||||
|
||||
if ((tmp = xoverview) != NULL) {
|
||||
// most_debug = TRUE;
|
||||
Syslog('N', "--Xoverview.fmt list");
|
||||
while (tmp != NULL) {
|
||||
if (tmp->header != NULL) {
|
||||
@ -527,7 +522,6 @@ int get_xoverview(void)
|
||||
}
|
||||
tmp = tmp->next;
|
||||
}
|
||||
// most_debug = FALSE;
|
||||
}
|
||||
} else {
|
||||
return 1;
|
||||
|
@ -59,7 +59,6 @@ extern int do_quiet;
|
||||
extern int do_unsec;
|
||||
extern int check_dupe;
|
||||
extern time_t t_start;
|
||||
extern int most_debug;
|
||||
|
||||
|
||||
|
||||
|
Reference in New Issue
Block a user