On 2002-08-13 09:21:57 -0400, Ryan Rothert wrote: > Shane, > Thanks I tried that. Now getting the following error: > > > cc -Wall -D_BSD_SOURCE -D_SVID_SOURCE -O2 main.c -o dbmail-smtp list.o > debug.o pipe.o mime.o dbmysql.o dbmd > 5.o md5.o bounce.o forward.o > memblock.o -L/opt/sfw/mysql/lib/mysql -lmysqlclient -lsocket -lnsl > cc -Wall -D_BSD_SOURCE -D_SVID_SOURCE -O2 pop3d.c -o dbmail-pop3d pop3.o > list.o debug.o dbmysql.o dbmd5.o md5.o > mime.o misc.o > memblock.o -L/opt/sfw/mysql/lib/mysql -lmysqlclient -lsocket -lnsl > pop3d.c: In function `handle_client': > pop3d.c:205: warning: int format, pid_t arg (arg 3) > pop3d.c: In function `main': > pop3d.c:323: warning: `n_max_connects' might be used uninitialized in this > function > Undefined first referenced > symbol in file > inet_aton /var/tmp//ccbYS3vC.o > ld: fatal: Symbol referencing errors. No output written to dbmail-pop3d > collect2: ld returned 1 exit status > make: *** [pop3d] Error 1
Right. I guess Solaris 9 *still* doesn't include that inet_aton() function. What do you expect for expensive, proprietary software? :( You need to use inet_addr() instead. You can try including the following: -[ begin code ]--------------------------------------------------------- #include <string.h> #include <netinet/in.h> int inet_aton (const char *cp, struct in_addr *inp) { unsigned int addr; addr = inet_addr(cp); if ((addr == INADDR_NONE) && (strcmp(cp, "255.255.255.255") != 0)) { return 0; } inp->s_addr = addr; return 1; } -[ end code ]----------------------------------------------------------- Stick this in some C file (maybe misc.c), and this should provide the same functionality. -- Shane Carpe Diem