summaryrefslogtreecommitdiff
path: root/extcap.c
diff options
context:
space:
mode:
Diffstat (limited to 'extcap.c')
-rw-r--r--extcap.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/extcap.c b/extcap.c
index 6087224df4..0835f7ce19 100644
--- a/extcap.c
+++ b/extcap.c
@@ -724,7 +724,7 @@ void extcap_if_cleanup(capture_options * capture_opts, gchar ** errormsg) {
{
if (userdata->extcap_stderr_rd > 0 && pipe_data_available(userdata->extcap_stderr_rd) )
{
- buffer = (gchar * )g_malloc0(sizeof(gchar) * STDERR_BUFFER_SIZE);
+ buffer = (gchar * )g_malloc0(sizeof(gchar) * STDERR_BUFFER_SIZE + 1);
#ifdef _WIN32
win32_readfrompipe((HANDLE)_get_osfhandle(userdata->extcap_stderr_rd), STDERR_BUFFER_SIZE, buffer);
#else