[2/2] parse-events: deref pointer for proper sizeof()
diff mbox series

Message ID 20190805102646.31142-2-sergey.senozhatsky@gmail.com
State Rejected
Headers show
Series
  • [1/2] parse-events: deref pointer for proper sizeof()
Related show

Commit Message

Sergey Senozhatsky Aug. 5, 2019, 10:26 a.m. UTC
Signed-off-by: Sergey Senozhatsky <sergey.senozhatsky@gmail.com>
---
 parse-events.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Patch
diff mbox series

diff --git a/parse-events.c b/parse-events.c
index 807fc53..1a25a7d 100644
--- a/parse-events.c
+++ b/parse-events.c
@@ -4778,7 +4778,7 @@  int pevent_register_event_handler(struct pevent *pevent,
  not_found:
 	/* Save for later use. */
 	handle = malloc_or_die(sizeof(*handle));
-	memset(handle, 0, sizeof(handle));
+	memset(handle, 0, sizeof(*handle));
 	handle->id = id;
 	if (event_name)
 		handle->event_name = strdup(event_name);