Skip to contentSkip to conversation

trace-event-python.c used malloc without checking ptr if NULL

PATCH New Heloise NH 1 participant 1 message Sep 30, 2015 perf events

lore
Share & tools
lore

Heloise NH

author
#0 lore raw

PATCH 1/1 trace-event-python.c used malloc without checking ptr if NULL

---
 tools/perf/util/scripting-engines/trace-event-python.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
tools/perf/util/scripting-engines/trace-event-python.c +1 -1
index cff58ae..14d8e73 100644
@@ -475,7 +475,7 @@ static int python_start_script(const char *script, int argc, const char **argv)
 	FILE *fp;
 
 	command_line = malloc((argc + 1) * sizeof(const char *));
-	if (command_line == NULL){
+	if (command_line == NULL) {
 		err = -1;
 		goto error;
 	}
Signature · 1 line
1.9.1