SecBSD's official ports repository
This commit is contained in:
commit
2c0afcbbf3
64331 changed files with 5339189 additions and 0 deletions
39
mail/popclient/patches/patch-socket_c
Normal file
39
mail/popclient/patches/patch-socket_c
Normal file
|
@ -0,0 +1,39 @@
|
|||
--- socket.c.orig 1995-08-14 20:36:48.000000000 +0200
|
||||
+++ socket.c 2004-01-05 01:06:02.000000000 +0100
|
||||
@@ -71,7 +71,7 @@
|
||||
#include <unistd.h>
|
||||
#endif
|
||||
#include <stdlib.h>
|
||||
-#include <varargs.h>
|
||||
+#include <stdarg.h>
|
||||
|
||||
#include "bzero.h"
|
||||
#include "socket.h"
|
||||
@@ -102,7 +102,7 @@ int clientPort;
|
||||
{
|
||||
hp = gethostbyname(host);
|
||||
if (hp == NULL)
|
||||
- return -1;
|
||||
+ return -2;
|
||||
memcpy(&ad.sin_addr, hp->h_addr, hp->h_length);
|
||||
}
|
||||
ad.sin_port = htons(clientPort);
|
||||
@@ -225,15 +225,13 @@ int len;
|
||||
}
|
||||
|
||||
|
||||
-int SockPrintf(socket,format,va_alist)
|
||||
-int socket;
|
||||
-char *format;
|
||||
-va_dcl {
|
||||
+int SockPrintf(int socket,char *format, ...)
|
||||
+{
|
||||
|
||||
va_list ap;
|
||||
char buf[8192];
|
||||
|
||||
- va_start(ap);
|
||||
+ va_start(ap, format);
|
||||
vsprintf(buf, format, ap);
|
||||
va_end(ap);
|
||||
return SockWrite(socket, buf, strlen(buf));
|
Loading…
Add table
Add a link
Reference in a new issue