-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 On 19 Jan 00, at 14:29, [EMAIL PROTECTED] wrote: > ugh... two seeks? Stat() is sooo much nicer ;-) > > #include <stdlib.h> > #include <unistd.h> > #include <sys/stat.h> > #include <sys/types.h> > > int main(void) { > struct stat st; > if (fstat(0, &st) < 0) _exit(111); > if (lseek(0,0,SEEK_SET)< 0) _exit(111); > if (st.st_size >= 128000L) > system("/var/qmail3/bin/forward \"$DEFAULT@$HOST\""); > else > system("/var/qmail2/bin/forward \"$DEFAULT@$HOST\""); > return 0; > } Yeah, it works, thanks. Now I am trying to get rid of the mid-inserted Delivered-To: alias-mailsize-something@somewhere line. I wouldn't care about this line, but it matters for forwarding (This_message_is_looping:_It_already_has_my_Delivered_To_line) a lot. I tried to filter out the Delivered-To: line before piping the text to /var/qmail?/bin/forward, but it doesn't help. (When I piped the message to "tee test.log | /var/qmail?/bin/forward", I saw no Delivered-To line in test.log.) Who actually appends the line then? forward? How do I get rid of it? Deleting DTLINE and/or RPLINE from environment? Thanks -----BEGIN PGP SIGNATURE----- Version: PGP 6.0.2 -- QDPGP 2.60 Comment: http://community.wow.net/grt/qdpgp.html iQA/AwUBOIbma1MwP8g7qbw/EQKXswCg/cG319bpDMYfWeg6DvG2f1OyK0YAoJTC XIqMrnUhabTUgH4zJmuB9aJy =TyOL -----END PGP SIGNATURE----- -- Petr Novotny, ANTEK CS [EMAIL PROTECTED] http://www.antek.cz PGP key ID: 0x3BA9BC3F -- Don't you know there ain't no devil there's just God when he's drunk. [Tom Waits]