Commit f2e71123 authored by Bastien Nocera's avatar Bastien Nocera

optical-media: Fix invalid read error when getting mounts

==8716== Invalid read of size 8
==8716==    at 0x48DEFA3: g_list_last (glist.c:930)
==8716==    by 0x48DEFEE: g_list_append (glist.c:270)
==8716==    by 0x150EC886: parsed_finished (grl-optical-media.c:576)
==8716==  Address 0x1068bed8 is 8 bytes inside a block of size 24 free'd
==8716==    at 0x483897B: free (in /usr/lib/x86_64-linux-gnu/valgrind/vgpreload_memcheck-amd64-linux.so)
==8716==    by 0x49014D1: g_slice_free_chain_with_offset (gslice.c:1231)
==8716==    by 0x150EC542: grl_optical_media_source_browse (grl-optical-media.c:639)
==8716==    by 0x487C3B2: browse_idle (grl-source.c:2487)
==8716==  Block was alloc'd at
==8716==    at 0x483774F: malloc (in /usr/lib/x86_64-linux-gnu/valgrind/vgpreload_memcheck-amd64-linux.so)
==8716==    by 0x48E8900: g_malloc (gmem.c:99)
==8716==    by 0x4900882: g_slice_alloc (gslice.c:1024)
==8716==    by 0x48DEFD3: g_list_append (glist.c:264)
==8716==    by 0x150EBA9A: parsed_finished_item (grl-optical-media.c:416)
parent 97e558a0
Pipeline #62676 passed with stage
in 3 minutes and 15 seconds