Another seenby experiment
This commit is contained in:
parent
6108ba6050
commit
0994b1f86f
@ -328,6 +328,7 @@ void ForwardFile(fidoaddr Node, fa_list *sbl)
|
|||||||
WriteError("$Can't create %s", fname);
|
WriteError("$Can't create %s", fname);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Syslog('p', "Forward almost done");
|
||||||
fsync(fileno(fl));
|
fsync(fileno(fl));
|
||||||
fclose(fl);
|
fclose(fl);
|
||||||
|
|
||||||
@ -343,6 +344,7 @@ void ForwardFile(fidoaddr Node, fa_list *sbl)
|
|||||||
free(queuedir);
|
free(queuedir);
|
||||||
free(listfile);
|
free(listfile);
|
||||||
tidy_faddr(routeto);
|
tidy_faddr(routeto);
|
||||||
|
Syslog('p', "Forward really done");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -731,11 +731,24 @@ int ProcessTic(fa_list *sbl)
|
|||||||
* Add all our system aka's to the seenby lines in the same zone
|
* Add all our system aka's to the seenby lines in the same zone
|
||||||
*/
|
*/
|
||||||
for (i = 0; i < 40; i++) {
|
for (i = 0; i < 40; i++) {
|
||||||
if (CFG.akavalid[i] && (tic.Aka.zone == CFG.aka[i].zone) /* &&
|
if (TIC.TicIn.Hatch) {
|
||||||
!((tic.Aka.net == CFG.aka[i].net) && (tic.Aka.node == CFG.aka[i].node)) */) {
|
/*
|
||||||
|
* Hatched file, add all aka's
|
||||||
|
*/
|
||||||
|
if (CFG.akavalid[i] && (tic.Aka.zone == CFG.aka[i].zone)) {
|
||||||
sprintf(sbe, "%u:%u/%u", CFG.aka[i].zone, CFG.aka[i].net, CFG.aka[i].node);
|
sprintf(sbe, "%u:%u/%u", CFG.aka[i].zone, CFG.aka[i].net, CFG.aka[i].node);
|
||||||
fill_list(&sbl, sbe, NULL);
|
fill_list(&sbl, sbe, NULL);
|
||||||
}
|
}
|
||||||
|
} else {
|
||||||
|
/*
|
||||||
|
* Incoming file, don't add the aka already in the ticfile of our system.
|
||||||
|
*/
|
||||||
|
if (CFG.akavalid[i] && (tic.Aka.zone == CFG.aka[i].zone) &&
|
||||||
|
!((tic.Aka.net == CFG.aka[i].net) && (tic.Aka.node == CFG.aka[i].node))) {
|
||||||
|
sprintf(sbe, "%u:%u/%u", CFG.aka[i].zone, CFG.aka[i].net, CFG.aka[i].node);
|
||||||
|
fill_list(&sbl, sbe, NULL);
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
@ -761,14 +774,20 @@ int ProcessTic(fa_list *sbl)
|
|||||||
while (GetTicSystem(&Link, First)) {
|
while (GetTicSystem(&Link, First)) {
|
||||||
First = FALSE;
|
First = FALSE;
|
||||||
if ((Link.aka.zone) && (Link.sendto) && (!Link.pause)) {
|
if ((Link.aka.zone) && (Link.sendto) && (!Link.pause)) {
|
||||||
|
Syslog('p', "Forward loop to %s", aka2str(Link.aka));
|
||||||
if (!((TIC.Aka.zone == Link.aka.zone) && (TIC.Aka.net == Link.aka.net) &&
|
if (!((TIC.Aka.zone == Link.aka.zone) && (TIC.Aka.net == Link.aka.net) &&
|
||||||
(TIC.Aka.node == Link.aka.node) && (TIC.Aka.point == Link.aka.point))) {
|
(TIC.Aka.node == Link.aka.node) && (TIC.Aka.point == Link.aka.point))) {
|
||||||
|
Syslog('p', "Will send");
|
||||||
tic_out++;
|
tic_out++;
|
||||||
ForwardFile(Link.aka, sbl);
|
ForwardFile(Link.aka, sbl);
|
||||||
|
Syslog('p', "Did send");
|
||||||
|
} else {
|
||||||
|
Syslog('p', "Will not send");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Syslog('p', "Forwarding to all nodes done");
|
||||||
|
|
||||||
Magic_ExecCommand();
|
Magic_ExecCommand();
|
||||||
Magic_CopyFile();
|
Magic_CopyFile();
|
||||||
@ -779,6 +798,7 @@ int ProcessTic(fa_list *sbl)
|
|||||||
|
|
||||||
unlink(Temp);
|
unlink(Temp);
|
||||||
free(Temp);
|
free(Temp);
|
||||||
|
Syslog('p', "ptic() done");
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user