From 28e811c09c5f32833906a5025137c947b2b7e0f6 Mon Sep 17 00:00:00 2001 From: Sebastien Helleu Date: Sat, 2 Feb 2008 21:12:16 +0100 Subject: Use of sizeof(char) in all malloc/realloc for strings --- src/core/wee-command.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/core/wee-command.c') diff --git a/src/core/wee-command.c b/src/core/wee-command.c index febc05c52..65cedc6a1 100644 --- a/src/core/wee-command.c +++ b/src/core/wee-command.c @@ -363,7 +363,7 @@ command_builtin (void *data, struct t_gui_buffer *buffer, else { length = strlen (argv_eol[1]) + 2; - command = (char *)malloc (length); + command = (char *)malloc (length * sizeof (char)); if (command) { snprintf (command, length, "/%s", argv_eol[1]); -- cgit v1.2.3