Lines Matching +refs:close +refs:socket
52 int socket = -1, i = 0; in OS_SendCustomEmail() local
66 socket = OS_ConnectTCP(SMTP_DEFAULT_PORT, smtpserver); in OS_SendCustomEmail()
67 if (socket < 0) { in OS_SendCustomEmail()
68 return (socket); in OS_SendCustomEmail()
72 msg = OS_RecvTCP(socket, OS_SIZE_1024); in OS_SendCustomEmail()
78 close(socket); in OS_SendCustomEmail()
85 OS_SendTCP(socket, HELOMSG); in OS_SendCustomEmail()
86 msg = OS_RecvTCP(socket, OS_SIZE_1024); in OS_SendCustomEmail()
96 msg = OS_RecvTCP(socket, OS_SIZE_1024); in OS_SendCustomEmail()
102 close(socket); in OS_SendCustomEmail()
108 close(socket); in OS_SendCustomEmail()
113 close(socket); in OS_SendCustomEmail()
124 OS_SendTCP(socket, snd_msg); in OS_SendCustomEmail()
125 msg = OS_RecvTCP(socket, OS_SIZE_1024); in OS_SendCustomEmail()
131 close(socket); in OS_SendCustomEmail()
141 OS_SendTCP(socket, snd_msg); in OS_SendCustomEmail()
142 msg = OS_RecvTCP(socket, OS_SIZE_1024); in OS_SendCustomEmail()
148 close(socket); in OS_SendCustomEmail()
158 OS_SendTCP(socket, DATAMSG); in OS_SendCustomEmail()
159 msg = OS_RecvTCP(socket, OS_SIZE_1024); in OS_SendCustomEmail()
165 close(socket); in OS_SendCustomEmail()
179 OS_SendTCP(socket, snd_msg); in OS_SendCustomEmail()
188 OS_SendTCP(socket, snd_msg); in OS_SendCustomEmail()
197 OS_SendTCP(socket, snd_msg); in OS_SendCustomEmail()
215 OS_SendTCP(socket, snd_msg); in OS_SendCustomEmail()
235 OS_SendTCP(socket, snd_msg); in OS_SendCustomEmail()
246 OS_SendTCP(socket, snd_msg); in OS_SendCustomEmail()
258 OS_SendTCP(socket, snd_msg); in OS_SendCustomEmail()
259 OS_SendTCP(socket, ENDHEADER); in OS_SendCustomEmail()
267 if(socket >= 0) { in OS_SendCustomEmail()
268 close(socket); in OS_SendCustomEmail()
285 if(socket >= 0) { in OS_SendCustomEmail()
286 close(socket); in OS_SendCustomEmail()
300 OS_SendTCP(socket, buffer); in OS_SendCustomEmail()
311 OS_SendTCP(socket, ENDDATA); in OS_SendCustomEmail()
312 msg = OS_RecvTCP(socket, OS_SIZE_1024); in OS_SendCustomEmail()
320 OS_SendTCP(socket, QUITMSG); in OS_SendCustomEmail()
321 msg = OS_RecvTCP(socket, OS_SIZE_1024); in OS_SendCustomEmail()
327 close(socket); in OS_SendCustomEmail()