/[imapfilter]/imapfilter/socket.c
ViewVC logotype

Diff of /imapfilter/socket.c

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.34 by lefcha, Sun Aug 3 16:07:06 2003 UTC revision 1.34.2.2 by lefcha, Fri Aug 8 12:25:51 2003 UTC
# Line 1  Line 1 
1  #include <stdio.h>  #include <stdio.h>
 #include <string.h>  
2  #include <unistd.h>  #include <unistd.h>
3    #include <string.h>
4  #include <errno.h>  #include <errno.h>
 #include <sys/types.h>  
 #include <sys/socket.h>  
5  #include <netinet/in.h>  #include <netinet/in.h>
6  #include <netdb.h>  #include <netdb.h>
7    #include <sys/socket.h>
8    #include <sys/types.h>          /* IEEE Std 1003.1-2001 non-conformance. */
9    #include <sys/time.h>           /* IEEE Std 1003.1-2001 non-conformance. */
10    #include <sys/select.h>
11  #include <fcntl.h>  #include <fcntl.h>
12    
13  #include "config.h"  #include "config.h"
# Line 14  Line 16 
16  #ifdef SSL_TLS  #ifdef SSL_TLS
17  #include <openssl/ssl.h>  #include <openssl/ssl.h>
18  #include <openssl/err.h>  #include <openssl/err.h>
 #include <openssl/x509.h>  
19  #endif  #endif
20    
21    
# Line 43  init_connection(conn_t * conn, char *ser Line 44  init_connection(conn_t * conn, char *ser
44    
45          memset((char *)&sa, 0, sizeof(struct sockaddr_in));          memset((char *)&sa, 0, sizeof(struct sockaddr_in));
46    
47          conn->sock = socket(PF_INET, SOCK_STREAM, 0);          conn->sock = socket(AF_INET, SOCK_STREAM, 0);
48    
49          if (conn->sock < 0) {          if (conn->sock < 0) {
50                  error("create socket; %s\n", strerror(errno));                  error("create socket; %s\n", strerror(errno));

Legend:
Removed from v.1.34  
changed lines
  Added in v.1.34.2.2

webmaster@linux.gr
ViewVC Help
Powered by ViewVC 1.1.26