1 #include "hdr.h" 2 #include "qmail.h" 3 #include "stralloc.h" 4 #include "quote.h" 5 #include "die.h" 6 #include "idx.h" 7 8 extern struct qmail qq; 9 extern stralloc outlocal; 10 extern stralloc outhost; 11 extern stralloc quoted; 12 hdr_from(const char * append)13void hdr_from(const char *append) 14 { 15 qmail_puts(&qq,"From: "); 16 if (!quote("ed,&outlocal)) 17 die_nomem(); 18 qmail_put(&qq,quoted.s,quoted.len); 19 if (append) 20 qmail_puts(&qq,append); 21 qmail_puts(&qq,"@"); 22 qmail_put(&qq,outhost.s,outhost.len); 23 qmail_puts(&qq,"\n"); 24 } 25