View Issue Details

IDProjectCategoryView StatusLast Update
0002363GNUnettransport servicepublic2012-06-02 19:15
ReporterMatthias Wachs Assigned ToMatthias Wachs  
PrioritynormalSeverityminorReproducibilityhave not tried
Status closedResolutionfixed 
Product VersionGit master 
Target Version0.9.3Fixed in Version0.9.3 
Summary0002363: Assertion failed at gnunet- service-transport_neighbours.c:836.
Description836: GNUNET_assert (GNUNET_YES ==
                 GNUNET_CONTAINER_multihashmap_remove (neighbours,
                                                       &n->id.hashPubKey, n));
Steps To Reproducerun nse-profiler and interrupt the test with control-c
Additional InformationA little bit strang ... there's only one line where neighbours are removed
TagsNo tags attached.

Activities

Matthias Wachs

2012-05-16 16:44

reporter   ~0005914

Added a debug message in free_neighbour

May 16 16:24:39-166330 transport-7757 ERROR Remove `0CQA'
May 16 16:24:39-166361 transport-7757 ERROR Remove `0CQA'
May 16 16:24:39-166372 transport-7757 ERROR Could not remove `0CQA'

Matthias Wachs

2012-05-16 16:50

reporter   ~0005915

peers are freed multiple times


#0 0x00007f63120ced05 in raise (sig=6) at ../nptl/sysdeps/unix/sysv/linux/raise.c:64
#1 0x00007f63120d2ab6 in abort () at abort.c:92
#2 0x00007f631210887b in __libc_message (do_abort=2, fmt=0x7f63121f10a0 "*** glibc detected *** %s: %s: 0x%s ***\n")
    at ../sysdeps/unix/sysv/linux/libc_fatal.c:189
#3 0x00007f631211458f in malloc_printerr (av=<value optimized out>, p=0x1ae15d0) at malloc.c:6283
#4 _int_free (av=<value optimized out>, p=0x1ae15d0) at malloc.c:4795
#5 0x00007f63121183e3 in __libc_free (mem=<value optimized out>) at malloc.c:3738
#6 0x00007f63128cc9dc in GNUNET_xfree_ (ptr=0x1ae15e0, filename=0x418328 "gnunet-service-transport_neighbours.c", linenumber=920)
    at common_allocation.c:201
#7 0x000000000040baaa in free_neighbour (n=0x1ae15e0) at gnunet-service-transport_neighbours.c:920
#8 0x000000000041328a in disconnect_all_neighbours (cls=0x0, key=0x7fff12ab5e60, value=0x1ae15e0) at gnunet-service-transport_neighbours.c:3107
#9 0x00007f63128dc203 in GNUNET_CONTAINER_multihashmap_iterate (map=0x1acd190, it=0x4131da <disconnect_all_neighbours>, it_cls=0x0)
    at container_multihashmap.c:213
#10 0x00000000004132ba in GST_neighbours_stop () at gnunet-service-transport_neighbours.c:3120
#11 0x0000000000404400 in shutdown_task (cls=0x0, tc=0x7fff12ab5f10) at gnunet-service-transport.c:533
#12 0x00007f63128fbf8d in run_ready (rs=0x1ad7840, ws=0x1ad78d0) at scheduler.c:602
#13 0x00007f63128fc796 in GNUNET_SCHEDULER_run (task=0x7f6312909528 <service_task>, task_cls=0x7fff12ab61f0) at scheduler.c:790
#14 0x00007f631290afc0 in GNUNET_SERVICE_run (argc=3, argv=0x7fff12ab6448, service_name=0x417397 "transport", options=GNUNET_SERVICE_OPTION_NONE,
    task=0x4044ac <run>, task_cls=0x0) at service.c:1773
#15 0x0000000000404a79 in main (argc=3, argv=0x7fff12ab6448) at gnunet-service-transport.c:646

Matthias Wachs

2012-05-16 17:13

reporter   ~0005916

==22645== Invalid free() / delete / delete[]
==22645== at 0x4C282ED: free (vg_replace_malloc.c:366)
==22645== by 0x565F9DB: GNUNET_xfree_ (common_allocation.c:201)
==22645== by 0x40BAA9: free_neighbour (gnunet-service-transport_neighbours.c:920)
==22645== by 0x413289: disconnect_all_neighbours (gnunet-service-transport_neighbours.c:3107)
==22645== by 0x566F202: GNUNET_CONTAINER_multihashmap_iterate (container_multihashmap.c:213)
==22645== by 0x4132B9: GST_neighbours_stop (gnunet-service-transport_neighbours.c:3120)
==22645== by 0x4043FF: shutdown_task (gnunet-service-transport.c:533)
==22645== by 0x568EF8C: run_ready (scheduler.c:602)
==22645== by 0x568F795: GNUNET_SCHEDULER_run (scheduler.c:790)
==22645== by 0x569DFBF: GNUNET_SERVICE_run (service.c:1773)
==22645== by 0x404A78: main (gnunet-service-transport.c:646)
==22645== Address 0x6d64e00 is 0 bytes inside a block of size 256 free'd
==22645== at 0x4C282ED: free (vg_replace_malloc.c:366)
==22645== by 0x565F9DB: GNUNET_xfree_ (common_allocation.c:201)
==22645== by 0x40BAA9: free_neighbour (gnunet-service-transport_neighbours.c:920)
==22645== by 0x412252: GST_neighbours_session_terminated (gnunet-service-transport_neighbours.c:2698)
==22645== by 0x403D4C: plugin_env_session_end (gnunet-service-transport.c:360)
==22645== by 0x70879C9: get_session_delete_it (plugin_transport_unix.c:293)
==22645== by 0x566F8B9: GNUNET_CONTAINER_multihashmap_get_multiple (container_multihashmap.c:485)
==22645== by 0x7087EA8: unix_disconnect (plugin_transport_unix.c:340)
==22645== by 0x40B8EC: free_neighbour (gnunet-service-transport_neighbours.c:889)
==22645== by 0x413289: disconnect_all_neighbours (gnunet-service-transport_neighbours.c:3107)
==22645== by 0x566F202: GNUNET_CONTAINER_multihashmap_iterate (container_multihashmap.c:213)
==22645== by 0x4132B9: GST_neighbours_stop (gnunet-service-transport_neighbours.c:3120)

Matthias Wachs

2012-05-16 17:14

reporter   ~0005917

NOTE: I removed the Assertion in multihashmap remove ... so it's a double free instead of the assertion

Matthias Wachs

2012-05-16 17:38

reporter   ~0005918

fixed in 21533.

Issue History

Date Modified Username Field Change
2012-05-16 14:55 Matthias Wachs New Issue
2012-05-16 14:55 Matthias Wachs Status new => assigned
2012-05-16 14:55 Matthias Wachs Assigned To => Matthias Wachs
2012-05-16 15:10 Matthias Wachs Steps to Reproduce Updated
2012-05-16 16:44 Matthias Wachs Note Added: 0005914
2012-05-16 16:50 Matthias Wachs Note Added: 0005915
2012-05-16 16:50 Matthias Wachs Steps to Reproduce Updated
2012-05-16 17:13 Matthias Wachs Note Added: 0005916
2012-05-16 17:14 Matthias Wachs Note Added: 0005917
2012-05-16 17:38 Matthias Wachs Note Added: 0005918
2012-05-16 17:41 Christian Grothoff Status assigned => resolved
2012-05-16 17:41 Christian Grothoff Fixed in Version => 0.9.3
2012-05-16 17:41 Christian Grothoff Resolution open => fixed
2012-05-16 17:41 Christian Grothoff Product Version => Git master
2012-05-16 17:41 Christian Grothoff Target Version => 0.9.3
2012-06-02 19:15 Christian Grothoff Status resolved => closed