[Spice-commits] src/channel-main.c

Victor Toso de Carvalho victortoso at kemper.freedesktop.org
Thu Mar 24 11:29:48 UTC 2016


 src/channel-main.c |    2 ++
 1 file changed, 2 insertions(+)

New commits:
commit e47075093d5d78b05a2b34fa7aee43dd6818f6ab
Author: Victor Toso <victortoso at redhat.com>
Date:   Wed Mar 23 15:40:50 2016 +0100

    channel-main: fix leak on volume-sync
    
    7 bytes in 1 blocks are definitely lost in loss record 128 of 10,009
       at 0x4C2A988: calloc (vg_replace_malloc.c:711)
       by 0xB6C3200: g_malloc0 (gmem.c:124)
       by 0x740BD5F: audio_playback_volume_info_cb (channel-main.c:1216)
       by 0xB11D488: g_task_return_now (gtask.c:1107)
       by 0xB11DCBD: g_task_return (gtask.c:1165)
       by 0x742D1F5: spice_pulse_complete_all_async_tasks (spice-pulse.c:1034)
       by 0x8B6B57C: ext_stream_restore_read_cb (ext-stream-restore.c:141)
       by 0x10BA63C0: run_action (pdispatch.c:284)
       by 0x10BA6722: pa_pdispatch_run (pdispatch.c:337)
       by 0x8B6520D: pstream_packet_callback (context.c:338)
       by 0x10BA8D7E: do_read (pstream.c:879)
       by 0x10BAB39A: do_pstream_read_write (pstream.c:189)
    
    7 bytes in 1 blocks are definitely lost in loss record 129 of 10,009
       at 0x4C2A988: calloc (vg_replace_malloc.c:711)
       by 0xB6C3200: g_malloc0 (gmem.c:124)
       by 0x740BFBF: audio_record_volume_info_cb (channel-main.c:1273)
       by 0xB11D488: g_task_return_now (gtask.c:1107)
       by 0xB11DCBD: g_task_return (gtask.c:1165)
       by 0x742D1F5: spice_pulse_complete_all_async_tasks (spice-pulse.c:1034)
       by 0x8B6B57C: ext_stream_restore_read_cb (ext-stream-restore.c:141)
       by 0x10BA63C0: run_action (pdispatch.c:284)
       by 0x10BA6722: pa_pdispatch_run (pdispatch.c:337)
       by 0x8B6520D: pstream_packet_callback (context.c:338)
       by 0x10BA8D7E: do_read (pstream.c:879)
       by 0x10BAB39A: do_pstream_read_write (pstream.c:189)
    
    Acked-by: Christophe Fergeau <cfergeau at redhat.com>

diff --git a/src/channel-main.c b/src/channel-main.c
index 1c19de1..8dd580a 100644
--- a/src/channel-main.c
+++ b/src/channel-main.c
@@ -1224,6 +1224,7 @@ static void audio_playback_volume_info_cb(GObject *object, GAsyncResult *res, gp
     g_free(volume);
     agent_msg_queue(main_channel, VD_AGENT_AUDIO_VOLUME_SYNC,
                     sizeof(VDAgentAudioVolumeSync) + array_size, avs);
+    g_free (avs);
 }
 
 static void agent_sync_audio_playback(SpiceMainChannel *main_channel)
@@ -1281,6 +1282,7 @@ static void audio_record_volume_info_cb(GObject *object, GAsyncResult *res, gpoi
     g_free(volume);
     agent_msg_queue(main_channel, VD_AGENT_AUDIO_VOLUME_SYNC,
                     sizeof(VDAgentAudioVolumeSync) + array_size, avs);
+    g_free (avs);
 }
 
 static void agent_sync_audio_record(SpiceMainChannel *main_channel)


More information about the Spice-commits mailing list