comparison libpurple/protocols/msn/directconn.c @ 25368:1260a3fb60f4

propagate from branch 'im.pidgin.pidgin' (head b8d6086aef6b2e65d86e8ce60220ab7f460d5079) to branch 'im.pidgin.pidgin.next.minor' (head c165595260a2efa0ca23704ada46a303e0412e19)
author Richard Laager <rlaager@wiktel.com>
date Fri, 12 Dec 2008 20:03:58 +0000
parents 146ee5c01696
children da33da2e1a1e
comparison
equal deleted inserted replaced
24661:d1d9d085d626 25368:1260a3fb60f4
199 g_free(str); 199 g_free(str);
200 #endif 200 #endif
201 201
202 g_free(buffer); 202 g_free(buffer);
203 203
204 #if 0
205 /* Let's write the length of the data. */
206 ret = write(directconn->fd, &len, sizeof(len));
207
208 /* Let's write the data. */
209 ret = write(directconn->fd, data, len);
210
211 char *str;
212 str = g_strdup_printf("/home/revo/msntest/w%.4d.bin", directconn->c);
213
214 FILE *tf = g_fopen(str, "w");
215 fwrite(&len, 1, sizeof(len), tf);
216 fwrite(data, 1, len, tf);
217 fclose(tf);
218
219 g_free(str);
220 #endif
221
222 directconn->c++; 204 directconn->c++;
223 205
224 return ret; 206 return ret;
225 } 207 }
226 208
339 if (len > 0) 321 if (len > 0)
340 { 322 {
341 MsnMessage *msg; 323 MsnMessage *msg;
342 324
343 #ifdef DEBUG_DC 325 #ifdef DEBUG_DC
344 str = g_strdup_printf("/home/revo/msntest/r%.4d.bin", directconn->c); 326 str = g_strdup_printf("%s/msntest/r%.4d.bin", g_get_home_dir(), directconn->c);
345 327
346 FILE *tf = g_fopen(str, "w"); 328 FILE *tf = g_fopen(str, "w");
347 fwrite(body, 1, len, tf); 329 fwrite(body, 1, len, tf);
348 fclose(tf); 330 fclose(tf);
349 331