Code cleanup
This commit is contained in:
parent
c854a40de6
commit
715932fe49
@ -3,6 +3,9 @@ $Id$
|
|||||||
|
|
||||||
v0.61.2 11-Jul-2004
|
v0.61.2 11-Jul-2004
|
||||||
|
|
||||||
|
libmbse.a:
|
||||||
|
Added logging for obsolete .tic files in .flo files.
|
||||||
|
|
||||||
|
|
||||||
v0.61.1 20-Jun-2004 - 11-Jul-2004
|
v0.61.1 20-Jun-2004 - 11-Jul-2004
|
||||||
|
|
||||||
|
7
TODO
7
TODO
@ -63,6 +63,13 @@ newuser:
|
|||||||
L: Allow handles to be the same as the unixname.
|
L: Allow handles to be the same as the unixname.
|
||||||
|
|
||||||
mbfido:
|
mbfido:
|
||||||
|
N: Check all .flo files for dead attachments.
|
||||||
|
|
||||||
|
N: Check all .flo files for to old attachments.
|
||||||
|
|
||||||
|
N: If a download file is deleted by keep # then check if the file(s)
|
||||||
|
are attached to nodes, if so delete the attachments and .tic files.
|
||||||
|
|
||||||
N: Count posted messages during mailscan.
|
N: Count posted messages during mailscan.
|
||||||
|
|
||||||
N: Code cleanup and make a structure in this program. Remove duplicate
|
N: Code cleanup and make a structure in this program. Remove duplicate
|
||||||
|
17
lib/attach.c
17
lib/attach.c
@ -113,8 +113,23 @@ int attach(faddr noden, char *ofile, int mode, char flavor)
|
|||||||
while (fgets(flofile, PATH_MAX -1, fp) != NULL) {
|
while (fgets(flofile, PATH_MAX -1, fp) != NULL) {
|
||||||
Striplf(flofile);
|
Striplf(flofile);
|
||||||
if (strncmp(flofile, thefile, strlen(thefile)) == 0) {
|
if (strncmp(flofile, thefile, strlen(thefile)) == 0) {
|
||||||
fclose(fp);
|
|
||||||
Syslog('+', "attach: file %s already attached", ofile);
|
Syslog('+', "attach: file %s already attached", ofile);
|
||||||
|
/*
|
||||||
|
* If one of the next entries in the .flo file is a .tic file
|
||||||
|
* pointing to this file, we should remove that .tic file and
|
||||||
|
* mark the entry in the .flo as sent. For the file with this
|
||||||
|
* name, a new .tic file will be added.
|
||||||
|
*/
|
||||||
|
while (fgets(flofile, PATH_MAX -1, fp) != NULL) {
|
||||||
|
Striplf(flofile);
|
||||||
|
if (strstr(flofile, (char *)".tic")) {
|
||||||
|
/*
|
||||||
|
* Check this .tic file
|
||||||
|
*/
|
||||||
|
Syslog('f', "Should check %s to be deleted", flofile);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
fclose(fp);
|
||||||
free(flofile);
|
free(flofile);
|
||||||
free(thefile);
|
free(thefile);
|
||||||
return TRUE;
|
return TRUE;
|
||||||
|
Reference in New Issue
Block a user