Hi,

I can reproduce this by these steps:

- wait for some connections
- set Proxy protocol to SOCKS4 (without having one)
- clear hostcaches so that GTKG tries to get some IPs from a GWC
- initiate an incoming connection (by adding localhost:PORT or telnet)
- quit GTKG

Looks like the socket was already freed.

** ERROR **: file /cvs/gtk-gnutella-current/src/sockets.c: line 163     
     (socket_free): assertion failed: (sl_incoming) aborting...

(gdb) bt
#0  0x48580890 in g_logv () from /usr/pkg/lib/libglib-2.0.so.200
#1  0x48580931 in g_log () from /usr/pkg/lib/libglib-2.0.so.200
#2  0x080c7417 in socket_free (s=0x8657000)
    at /cvs/gtk-gnutella-current/src/sockets.c:163
#3  0x08116101 in http_async_free_recursive (ha=0x8405090)
    at /cvs/gtk-gnutella-current/src/http.c:1204
#4  0x0811631f in http_async_free (ha=0x8405090)
    at /cvs/gtk-gnutella-current/src/http.c:1271
#5  0x08116467 in http_async_remove (handle=0x8405090,
#type=HTTP_ASYNC_ERROR, 
    code=0x6) at /cvs/gtk-gnutella-current/src/http.c:1321
#6  0x0811649c in http_async_error (handle=0x8405090, code=6)
    at /cvs/gtk-gnutella-current/src/http.c:1341
#7  0x08117673 in http_close ()
    at /cvs/gtk-gnutella-current/src/http.c:2041
#8  0x080f5744 in gtk_gnutella_exit (n=0)
    at /cvs/gtk-gnutella-current/src/main.c:111
#9  0x080b4bb9 in quit (force=0)
    at /cvs/gtk-gnutella-current/src/main_cb.c:44
#10 0x080b4bfc in on_button_quit_clicked (button=0x832c800,
#user_data=0x0)
    at /cvs/gtk-gnutella-current/src/main_cb.c:62
#11 0x4853deb2 in g_cclosure_marshal_VOID__VOID ()
   from /usr/pkg/lib/libgobject-2.0.so.200
#12 0x4852d576 in g_closure_invoke () from
#/usr/pkg/lib/libgobject-2.0.so.200 13 0x4853d88e in
#signal_emit_unlocked_R ()
   from /usr/pkg/lib/libgobject-2.0.so.200
#14 0x4853cdde in g_signal_emit_valist ()
   from /usr/pkg/lib/libgobject-2.0.so.200
#15 0x4853d081 in g_signal_emit () from
#/usr/pkg/lib/libgobject-2.0.so.200 16 0x4836ade1 in gtk_widget_activate
#()
   from /usr/pkg/lib/libgtk-x11-2.0.so.200
#17 0x4827080e in gtk_menu_shell_activate_item ()
   from /usr/pkg/lib/libgtk-x11-2.0.so.200
#18 0x4826f458 in gtk_menu_shell_deactivate ()
   from /usr/pkg/lib/libgtk-x11-2.0.so.200
#19 0x4826668b in gtk_menu_reorder_child ()
   from /usr/pkg/lib/libgtk-x11-2.0.so.200
#20 0x4825c4b0 in gtk_propagate_event ()
   from /usr/pkg/lib/libgtk-x11-2.0.so.200
#21 0x4852d7bd in g_type_class_meta_marshal ()
   from /usr/pkg/lib/libgobject-2.0.so.200
#22 0x4852d576 in g_closure_invoke () from
#/usr/pkg/lib/libgobject-2.0.so.200 23 0x4853d9f7 in
#signal_emit_unlocked_R ()
   from /usr/pkg/lib/libgobject-2.0.so.200
#24 0x4853ce4d in g_signal_emit_valist ()
   from /usr/pkg/lib/libgobject-2.0.so.200
#25 0x4853d081 in g_signal_emit () from
#/usr/pkg/lib/libgobject-2.0.so.200 26 0x4836acbb in
#gtk_widget_send_expose ()
   from /usr/pkg/lib/libgtk-x11-2.0.so.200
#27 0x4836a8bc in gtk_widget_event () from
#/usr/pkg/lib/libgtk-x11-2.0.so.200 28 0x4825c2ec in gtk_propagate_event
#()
   from /usr/pkg/lib/libgtk-x11-2.0.so.200
#29 0x4825ac26 in gtk_main_do_event () from
#/usr/pkg/lib/libgtk-x11-2.0.so.200 30 0x4845e01c in
#gdk_add_client_message_filter ()
   from /usr/pkg/lib/libgdk-x11-2.0.so.200
#31 0x4857988b in g_main_dispatch () from
#/usr/pkg/lib/libglib-2.0.so.200 32 0x4857a627 in
#g_main_context_dispatch ()
   from /usr/pkg/lib/libglib-2.0.so.200
#33 0x4857a9fa in g_main_context_iterate ()
   from /usr/pkg/lib/libglib-2.0.so.200
#34 0x4857b0c7 in g_main_loop_run () from
#/usr/pkg/lib/libglib-2.0.so.200 35 0x4825a31d in gtk_main () from
#/usr/pkg/lib/libgtk-x11-2.0.so.200 36 0x080b4a12 in main_gui_run ()
    at /cvs/gtk-gnutella-current/src/main_gui.c:565
#37 0x080f5e15 in main (argc=1, argv=0xbfbfb96c)
    at /cvs/gtk-gnutella-current/src/main.c:425
#38 0x08052140 in ___start ()
(gdb) f 2   
#2  0x080c7417 in socket_free (s=0x8657000)
    at /cvs/gtk-gnutella-current/src/sockets.c:163
163                     g_assert(sl_incoming);
(gdb) p *s
$1 = {file_desc = 1213472803, gdk_tag = 1176523593, direction =
541412425,   type = 1092637513, corked = 1297044565, adns_pending =
1128879169,   ip = 1498172481, port = 18208, local_port = 20037,
last_update = 1413567045,   resource = {node = 0x2d204445, download =
0x2d204445, upload = 0x2d204445,     handle = 0x2d204445}, getline =
0x4f44202d,   buffer = " NOT EDIT\n#\n# Saved on Thu Feb 27 22:08:27
2003\n\n# Format is:\n#\tNAME <file name>\n#\tPATH <path>\n#\tGENR
<generation number>\n#\tALIA <alias file name>\n#\tSIZE <size>\n#\tSHA1
<server sha1>\n#\tCHA1 <computed s"...,   pos = 0}
(gdb) f 3
#3  0x08116101 in http_async_free_recursive (ha=0x8405090)
    at /cvs/gtk-gnutella-current/src/http.c:1204
1204                    socket_free(ha->socket);
(gdb) p *ha
$5 = {magic = -1457720338, type = HTTP_GET, flags = 0, 
  url = 0x864a084
"http://63.164.33.64/gnutella/gcache.php/?hostfile=1&client=GTKG&versio
n=0.92u",   path = 0x84c7184
"/gnutella/gcache.php/?hostfile=1&client=GTKG&version=0.92u", host =
0x85ae524 "63.164.33.64", socket = 0x8657000, header_ind = 0,   data_ind
= 0x811bd8c <gwc_host_data_ind>,   error_ind = 0x811bdb2
<gwc_host_error_ind>, last_update = 1046380107,   io_opaque = 0x0, bio =
0x0, user_opaque = 0x8406000,   user_free = 0x811b706
<parse_context_free>, parent = 0x0, children = 0x0}

Christian

Attachment: pgp00000.pgp
Description: PGP signature

Reply via email to