Mercurial > masqmail
comparison src/listen.c @ 378:5781ba87df95
Removed ident. This had been discussed on the mailing list in Oct 2011.
Ident is hardly useful in typical setups for masqmail. Probably Oliver
had used it in his setup; that would make sense. Now, I know of nobody
who needs it.
author | markus schnalke <meillo@marmaro.de> |
---|---|
date | Sat, 14 Jan 2012 21:36:58 +0100 |
parents | b27f66555ba8 |
children | a2909de1818b |
comparison
equal
deleted
inserted
replaced
377:9bc3e47b0222 | 378:5781ba87df95 |
---|---|
55 FILE *out, *in; | 55 FILE *out, *in; |
56 gchar *rem_host; | 56 gchar *rem_host; |
57 gchar *ident = NULL; | 57 gchar *ident = NULL; |
58 | 58 |
59 rem_host = g_strdup(inet_ntoa(sock_addr->sin_addr)); | 59 rem_host = g_strdup(inet_ntoa(sock_addr->sin_addr)); |
60 #ifdef ENABLE_IDENT | |
61 { | |
62 gchar *id = NULL; | |
63 if ((id = (gchar *) ident_id(sock, 60))) { | |
64 ident = g_strdup(id); | |
65 } | |
66 logwrite(LOG_NOTICE, "connect from host %s, port %hd ident=%s\n", rem_host, | |
67 ntohs(sock_addr->sin_port), ident ? ident : "(unknown)"); | |
68 } | |
69 #else | |
70 logwrite(LOG_NOTICE, "connect from host %s, port %hd\n", rem_host, ntohs(sock_addr->sin_port)); | 60 logwrite(LOG_NOTICE, "connect from host %s, port %hd\n", rem_host, ntohs(sock_addr->sin_port)); |
71 #endif | |
72 | 61 |
73 /* start child for connection: */ | 62 /* start child for connection: */ |
74 signal(SIGCHLD, sigchld_handler); | 63 signal(SIGCHLD, sigchld_handler); |
75 pid = fork(); | 64 pid = fork(); |
76 if (pid == 0) { | 65 if (pid == 0) { |
82 | 71 |
83 _exit(0); | 72 _exit(0); |
84 } else if (pid < 0) { | 73 } else if (pid < 0) { |
85 logwrite(LOG_WARNING, "could not fork for incoming smtp connection: %s\n", strerror(errno)); | 74 logwrite(LOG_WARNING, "could not fork for incoming smtp connection: %s\n", strerror(errno)); |
86 } | 75 } |
87 #ifdef ENABLE_IDENT | |
88 if (ident != NULL) | |
89 g_free(ident); | |
90 #endif | |
91 | 76 |
92 close(sock); | 77 close(sock); |
93 close(dup_sock); | 78 close(dup_sock); |
94 } | 79 } |
95 | 80 |