Skip to contentSkip to conversation

gdbstub: Drop redundant memset after qemu_mallocz

PATCH Applied Jan Kiszka 2 participants 2 messages Mar 17, 2009 – Mar 28, 2009

lore
Share & tools
lore

Jan Kiszka

author
#0 lore raw

PATCH 1/1 gdbstub: Drop redundant memset after qemu_mallocz

---

 gdbstub.c |    2 --
 1 files changed, 0 insertions(+), 2 deletions(-)
gdbstub.c +0 -2
index 1191dc2..935d864 100644
@@ -2274,8 +2274,6 @@ static void gdb_accept(void)
     setsockopt(fd, IPPROTO_TCP, TCP_NODELAY, (char *)&val, sizeof(val));
 
     s = qemu_mallocz(sizeof(GDBState));
-
-    memset (s, 0, sizeof (GDBState));
     s->c_cpu = first_cpu;
     s->g_cpu = first_cpu;
     s->fd = fd;
#1 lore raw
Quoted 2 lines · Jan Kiszka

Applied. Thanks.

Regards,

Anthony Liguori

Quoted 22 lines

---

 gdbstub.c |    2 --
 1 files changed, 0 insertions(+), 2 deletions(-)
gdbstub.c +0 -2
index 1191dc2..935d864 100644
@@ -2274,8 +2274,6 @@ static void gdb_accept(void)
     setsockopt(fd, IPPROTO_TCP, TCP_NODELAY, (char *)&val, sizeof(val));
 
     s = qemu_mallocz(sizeof(GDBState));
-
-    memset (s, 0, sizeof (GDBState));
     s->c_cpu = first_cpu;
     s->g_cpu = first_cpu;
     s->fd = fd;