Commit d76fc56e authored by Per Cederqvist's avatar Per Cederqvist
Browse files

Don't include <sys/socket.h> (included from "isc.h").

Check HAVE_STRING_H and HAVE_STDLIB_H.
parent 5e2264d5
......@@ -9,17 +9,20 @@
*/
#include <errno.h>
#include <stdlib.h>
#ifdef HAVE_STDLIB_H
# include <stdlib.h>
#endif
#include <stddef.h>
#include <ctype.h>
#include <sys/types.h>
#include <sys/socket.h>
#include <netinet/in.h>
#include <arpa/inet.h>
#include <sys/file.h>
#include <sys/ioctl.h>
#include <netdb.h>
#include <string.h>
#ifdef HAVE_STRING_H
# include <string.h>
#endif
#include <fcntl.h>
#include "isc.h"
......@@ -35,12 +38,12 @@
extern int socket(int, int, int);
/*extern int setsockopt(int, int, int, char *, int);*/
extern int listen(int, int);
extern int connect(int, struct sockaddr *, int);
extern int bind(int, struct sockaddr *, int);
/*extern int connect(int, struct sockaddr *, int);*/
/*extern int bind(int, struct sockaddr *, int);*/
extern int close(int);
/*extern int atoi(const char *str);*/
extern time_t sleep(time_t);
extern int accept(int fd, struct sockaddr *sock, int *len);
/*extern int accept(int fd, struct sockaddr *sock, int *len);*/
......
......@@ -10,16 +10,19 @@
#include <sys/types.h>
#include <errno.h>
#include <stdlib.h>
#ifdef HAVE_STDLIB_H
# include <stdlib.h>
#endif
#include <stddef.h>
#include <ctype.h>
#include <netinet/in.h>
#include <sys/socket.h>
#include <arpa/inet.h>
#include <sys/file.h>
#include <sys/ioctl.h>
#include <netdb.h>
#include <string.h>
#ifdef HAVE_STRING_H
# include <string.h>
#endif
#include <fcntl.h>
#include "isc.h"
......@@ -31,8 +34,8 @@
/*extern void *memcpy(void *, const void *, int);*/
extern int socket(int, int, int);
/*extern int setsockopt(int, int, int, char *, int);*/
extern int connect(int, struct sockaddr *, int);
extern int bind(int, struct sockaddr *, int);
/*extern int connect(int, struct sockaddr *, int);*/
/*extern int bind(int, struct sockaddr *, int);*/
extern int close(int);
/*extern int atoi(const char *str);*/
/*extern int recvfrom(int fd, char *buf, int len, int flags,
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment