From b732a73bc773789894466b0e5320b2f1fe42c7e9 Mon Sep 17 00:00:00 2001 From: John Denker Date: Fri, 1 Jun 2012 18:58:45 -0700 Subject: original, as downloaded from http://www.qmail.org/netqmail-1.06.tar.gz --- ipmeprint.c | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) create mode 100644 ipmeprint.c (limited to 'ipmeprint.c') diff --git a/ipmeprint.c b/ipmeprint.c new file mode 100644 index 0000000..1ef56e3 --- /dev/null +++ b/ipmeprint.c @@ -0,0 +1,24 @@ +#include "subfd.h" +#include "substdio.h" +#include "ip.h" +#include "ipme.h" +#include "exit.h" + +char temp[IPFMT]; + +void main() +{ + int j; + switch(ipme_init()) + { + case 0: substdio_putsflush(subfderr,"out of memory\n"); _exit(111); + case -1: substdio_putsflush(subfderr,"hard error\n"); _exit(100); + } + for (j = 0;j < ipme.len;++j) + { + substdio_put(subfdout,temp,ip_fmt(temp,&ipme.ix[j].ip)); + substdio_puts(subfdout,"\n"); + } + substdio_flush(subfdout); + _exit(0); +} -- cgit v1.2.3