From 86699c2035dd69428706ade2d6dfb150ada757cb Mon Sep 17 00:00:00 2001 From: Nils Carlson Date: Thu, 30 Sep 2010 10:09:04 +0200 Subject: [PATCH] Fix a zmalloc bug sizeof(void *) was allocated instead of sizeof(struct probe). Signed-off-by: Nils Carlson --- libust/tracepoint.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libust/tracepoint.c b/libust/tracepoint.c index 2b33d84..6fe9cd7 100644 --- a/libust/tracepoint.c +++ b/libust/tracepoint.c @@ -74,7 +74,7 @@ struct tp_probes { static inline void *allocate_probes(int count) { - struct tp_probes *p = zmalloc(count * sizeof(void *) + struct tp_probes *p = zmalloc(count * sizeof(struct probe) + sizeof(struct tp_probes)); return p == NULL ? NULL : p->probes; } -- 2.34.1