Some small updates

This commit is contained in:
Michiel Broek
2003-02-12 20:20:59 +00:00
parent 75831ac20c
commit 8def403243
7 changed files with 58 additions and 56 deletions

View File

@@ -296,13 +296,18 @@ int main(int argc, char **argv)
}
if (execute(cmd, nd, (char *)NULL, (char *)"/dev/null", (char *)"/dev/null", (char *)"/dev/null")) {
show_log = TRUE;
free(cmd);
free(onl);
free(wrk);
free(ond);
WriteError("Unpack error");
die(MBERR_EXEC_FAILED);
Syslog('!', "Warning: unpack error, trying again after a sync");
sync();
sleep(1);
if (execute(cmd, nd, (char *)NULL, (char *)"/dev/null", (char *)"/dev/null", (char *)"/dev/null")) {
show_log = TRUE;
free(cmd);
free(onl);
free(wrk);
free(ond);
WriteError("Fatal: unpack error");
die(MBERR_EXEC_FAILED);
}
}
free(cmd);
sync();

View File

@@ -144,7 +144,7 @@ int postecho(faddr *p_from, faddr *f, faddr *t, char *orig, char *subj, time_t m
{
char *buf, *msgid = NULL, *reply = NULL, *p, *q, sbe[16];
int First = TRUE, rc = 0, i, kludges = TRUE, dupe = FALSE, bad = TRUE, seenlen, oldnet;
faddr *Faddr, *ta;
faddr *Faddr;
unsigned long crc;
sysconnect Link;
fa_list *sbl = NULL, *ptl = NULL, *tmpl;
@@ -221,28 +221,13 @@ int postecho(faddr *p_from, faddr *f, faddr *t, char *orig, char *subj, time_t m
}
if (!strncmp(buf, "\001MSGID: ", 8)) {
msgid = xstrcpy(buf + 8);
/*
* Extra test to see if the address is correct, only logging.
*/
p = strtok(buf, " \n");
p = strtok(NULL, " \n");
if ((ta = parsefnode(p))) {
if ((ta->zone != f->zone) || (ta->point != f->point) || (ta->node != f->node) || (ta->net != f->net)) {
p = xstrcpy(ascfnode(f, 0x1f));
Syslog('!', "ERROR: origin=%s, msgid=%s", p, ascfnode(ta, 0x1f));
free(p);
}
}
}
if (!strncmp(buf, "\001REPLY: ", 8))
reply = xstrcpy(buf + 8);
if (!strncmp(buf, "SEEN-BY:", 8)) {
// if (Link.aka.zone == msgs.Aka.zone) {
p = xstrcpy(buf + 9);
fill_list(&sbl, p, NULL);
free(p);
// } else
// Syslog('m', "Strip zone SB lines");
p = xstrcpy(buf + 9);
fill_list(&sbl, p, NULL);
free(p);
}
if (!strncmp(buf, "\001PATH:", 6)) {
p = xstrcpy(buf + 7);