Mercurial > dropbear
comparison listener.c @ 165:0cfba3034be5
Fixed DEBUG_TRACE macro so that we don't get semicolons left about the place
author | Matt Johnston <matt@ucc.asn.au> |
---|---|
date | Sun, 02 Jan 2005 20:25:56 +0000 |
parents | e3adf4cf5465 |
children | 2b4fd440399d |
comparison
equal
deleted
inserted
replaced
161:b9d3f725e00b | 165:0cfba3034be5 |
---|---|
91 } | 91 } |
92 | 92 |
93 /* or create a new one */ | 93 /* or create a new one */ |
94 if (i == ses.listensize) { | 94 if (i == ses.listensize) { |
95 if (ses.listensize > MAX_LISTENERS) { | 95 if (ses.listensize > MAX_LISTENERS) { |
96 TRACE(("leave newlistener: too many already")); | 96 TRACE(("leave newlistener: too many already")) |
97 for (j = 0; j < nsocks; j++) { | 97 for (j = 0; j < nsocks; j++) { |
98 close(socks[i]); | 98 close(socks[i]); |
99 } | 99 } |
100 return NULL; | 100 return NULL; |
101 } | 101 } |
113 | 113 |
114 for (j = 0; j < nsocks; j++) { | 114 for (j = 0; j < nsocks; j++) { |
115 ses.maxfd = MAX(ses.maxfd, socks[j]); | 115 ses.maxfd = MAX(ses.maxfd, socks[j]); |
116 } | 116 } |
117 | 117 |
118 TRACE(("new listener num %d ", i)); | 118 TRACE(("new listener num %d ", i)) |
119 | 119 |
120 newlisten = (struct Listener*)m_malloc(sizeof(struct Listener)); | 120 newlisten = (struct Listener*)m_malloc(sizeof(struct Listener)); |
121 newlisten->index = i; | 121 newlisten->index = i; |
122 newlisten->type = type; | 122 newlisten->type = type; |
123 newlisten->typedata = typedata; | 123 newlisten->typedata = typedata; |