]> git.proxmox.com Git - qemu.git/commit - gdbstub.c
gdbstub: Fix memory leak
authorStefan Weil <sw@weilnetz.de>
Tue, 18 Oct 2011 20:25:38 +0000 (22:25 +0200)
committerBlue Swirl <blauwirbel@gmail.com>
Sat, 19 Nov 2011 11:22:24 +0000 (11:22 +0000)
commit9643c25f8d67646857159d6fc021b07e7a659192
tree3ce5f4b6a32c0d3dd814e27937a11d3334680dfe
parentb08d26b76d51fb2695912373ded53b628ec96320
gdbstub: Fix memory leak

cppcheck report:
  gdbstub.c:1781: error: Memory leak: s

Rearranging of the code avoids the leak.

v2:
Replace the g_malloc0() by g_new0() (suggested by Stuart Brady).

Signed-off-by: Stefan Weil <sw@weilnetz.de>
Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
gdbstub.c