Subj : makenl msgids To : mark lewis From : Vince Coen Date : Mon Jul 29 2019 12:55:39 Hello mark! Monday July 29 2019 00:21, you wrote to all: I am now really confused - I use 3.5.0 compiled on a X64 system and it produces 8 char sequence numbers. > On 2019 Jul 28 14:14:20, I wrote to you: ml>> has anyone else noticed that makenl is generating 10 character ml>> serial numbers? > the problem is here... specifically, %08lx does not set the maximum > length... only the minimum... > fprintf(MailFILE, "\x01MSGID: %d:%d/%d %08lx\r\n", > MyAddress[A_ZONE], > MyAddress[A_NET], MyAddress[A_NODE], GetSequence()); > something like this should work but i'm not a C coder and haven't > tried to actually compile something to test this with... > char* serialnum = printf("%08lx", GetSequence()); > if (strlen(serialnum) > 8) > { > serialnum = serialnum + strlen(serialnum) - 8; > } > fprintf(MailFILE, "\x01MSGID: %d:%d/%d %s\r\n", MyAddress[A_ZONE], > MyAddress[A_NET], MyAddress[A_NODE], serialnum); > )\/(ark > Once men turned their thinking over to machines in the hope that this > would set them free. But that only permitted other men with machines > to enslave them. > ... Why do croutons come in airtight packages? It's just stale bread. Vince --- Mageia Linux v6 X64/Mbse v1.0.7.12/GoldED+/LNX 1.1.501-b20150715 * Origin: Air Applewood, The Linux Gateway to the UK & Eire (2:250/1) .