comparison src/ssl-nss.c @ 6759:f9efcba2d02f

[gaim-migrate @ 7291] Added input watchers for the Mozilla NSS support. Should work. committer: Tailor Script <tailor@pidgin.im>
author Christian Hammond <chipx86@chipx86.com>
date Sat, 06 Sep 2003 01:08:55 +0000
parents 82348b5ab87e
children 6d0d4e9149b9
comparison
equal deleted inserted replaced
6758:424647996866 6759:f9efcba2d02f
119 119
120 static void 120 static void
121 input_func(gpointer data, gint source, GaimInputCondition cond) 121 input_func(gpointer data, gint source, GaimInputCondition cond)
122 { 122 {
123 GaimSslConnection *gsc = (GaimSslConnection *)data; 123 GaimSslConnection *gsc = (GaimSslConnection *)data;
124 #if 0
124 GaimSslNssData *nss_data = GAIM_SSL_NSS_DATA(gsc); 125 GaimSslNssData *nss_data = GAIM_SSL_NSS_DATA(gsc);
125 char *cp, *ip, *sp; 126 char *cp, *ip, *sp;
126 int op, kp0, kp1; 127 int op, kp0, kp1;
127 int result; 128 int result;
128 129
136 cp, kp1, kp0, op, sp, ip); 137 cp, kp1, kp0, op, sp, ip);
137 138
138 PR_Free(cp); 139 PR_Free(cp);
139 PR_Free(ip); 140 PR_Free(ip);
140 PR_Free(sp); 141 PR_Free(sp);
142 #endif
141 143
142 gsc->input_func(gsc->user_data, gsc, cond); 144 gsc->input_func(gsc->user_data, gsc, cond);
143 } 145 }
144 146
145 static gboolean 147 static gboolean
218 220
219 if (SSL_ForceHandshake(nss_data->in)) 221 if (SSL_ForceHandshake(nss_data->in))
220 { 222 {
221 gaim_debug_error("nss", "Handshake failed\n"); 223 gaim_debug_error("nss", "Handshake failed\n");
222 224
223 gaim_ssl_close((GaimSslConnection *)gsc); 225 gaim_ssl_close(gsc);
224 226
225 return; 227 return;
226 } 228 }
227 229
228 #if 0 230 gsc->inpa = gaim_input_add(gsc->fd,
229 gsc->input_func(gsc->user_data, (GaimSslConnection *)gsc, 231 GAIM_INPUT_READ | GAIM_INPUT_WRITE,
230 cond); 232 input_func, gsc);
231 #endif
232
233 input_func(gsc, source, cond);
234 } 233 }
235 234
236 static void 235 static void
237 ssl_nss_close(GaimSslConnection *gsc) 236 ssl_nss_close(GaimSslConnection *gsc)
238 { 237 {