Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: PATCH: zftp without inet_aton()



Sven Wischnowsky wrote:
>Quick fix below (can't move the includes below the arpa thingies
>because at least my arpa/telnet.h #defines DO, which would then cause
>mishap in zsh.h:212).

The proper fix is to add struct in_addr to the list of forward structure
declarations.  This patch applies on top of 8831, though only to
reverse it.

-zefram

diff -u -r ../zsh-/Src/Modules/zftp.c ./Src/Modules/zftp.c
--- ../zsh-/Src/Modules/zftp.c	Wed Dec  1 09:26:06 1999
+++ ./Src/Modules/zftp.c	Wed Dec  1 09:27:42 1999
@@ -43,21 +43,21 @@
 
 /* needed in prototypes for statics */
 struct hostent;
+struct in_addr;
 struct sockaddr_in;
 struct sockaddr_in6;
 union zftp_sockaddr;
 struct zftp_session;
 typedef struct zftp_session *Zftp_session;
 
+#include "zftp.mdh"
+#include "zftp.pro"
+
 #include <sys/socket.h>
 #include <netdb.h>
 #include <netinet/in_systm.h>
 #include <netinet/in.h>
 #include <netinet/ip.h>
-
-#include "zftp.mdh"
-#include "zftp.pro"
-
 #include <arpa/inet.h>
 /* it's a TELNET based protocol, but don't think I like doing this */
 #include <arpa/telnet.h>
END



Messages sorted by: Reverse Date, Date, Thread, Author