Bugfix for areamgr, changed No Touch flag, doc updates

This commit is contained in:
Michiel Broek
2002-05-29 19:53:42 +00:00
parent 91f59e902c
commit 74e18ac52a
13 changed files with 33 additions and 21 deletions

View File

@@ -345,7 +345,7 @@ int CheckTicGroup(char *Area, int SendUplink, faddr *f)
tic.Replace = fgroup.Replace;
tic.DupCheck = fgroup.DupCheck;
tic.Secure = fgroup.Secure;
tic.NoTouch = fgroup.NoTouch;
tic.Touch = fgroup.Touch;
tic.VirScan = fgroup.VirScan;
tic.Announce = fgroup.Announce;
tic.UpdMagic = fgroup.UpdMagic;

View File

@@ -139,12 +139,14 @@ int CheckEchoGroup(char *Area, int SendUplink, faddr *f)
return 1;
}
fread(&msgshdr, sizeof(msgshdr), 1, mp);
offset = msgshdr.hdrsize + ((mgroup.StartArea -1) * (msgshdr.recsize + msgshdr.syssize));
Syslog('+', "file end at %ld, offset needed %ld", ftell(mp), offset);
/*
* Verify the file is large enough
*/
fseek(mp, 0, SEEK_END);
offset = msgshdr.hdrsize + ((mgroup.StartArea -1) * (msgshdr.recsize + msgshdr.syssize));
Syslog('+', "file end at %ld, offset needed %ld", ftell(mp), offset);
if (ftell(mp) < offset) {
Syslog('m', "Database too small, expanding...");
memset(&msgs, 0, sizeof(msgs));
@@ -159,7 +161,7 @@ int CheckEchoGroup(char *Area, int SendUplink, faddr *f)
}
if (fseek(mp, offset, SEEK_SET)) {
WriteError("$Can't seek in %s", temp);
WriteError("$Can't seek in %s to position %ld", temp, offset);
fclose(ap);
fclose(mp);
free(buf);

View File

@@ -670,7 +670,7 @@ int ProcessTic(fa_list *sbl)
* received file as the file creation date.
*/
if (MustRearc || DidBanner) {
if ((!tic.NoTouch) && (tic.FileArea)) {
if ((tic.Touch) && (tic.FileArea)) {
ut.actime = mktime(localtime(&TIC.FileDate));
ut.modtime = mktime(localtime(&TIC.FileDate));
sprintf(Temp, "%s/%s", TIC.Inbound, TIC.NewName);