[Xfce4-commits] [panel-plugins/xfce4-netload-plugin] 02/04: Fix array out of bounds write
noreply at xfce.org
noreply at xfce.org
Fri Jun 9 12:30:16 CEST 2017
This is an automated email from the git hooks/post-receive script.
s k u n n y k p u s h e d a c o m m i t t o b r a n c h m a s t e r
in repository panel-plugins/xfce4-netload-plugin.
commit 17ba2f635b9bcc02415e12ab0f4cfbeb920e1377
Author: Guido Berhoerster <guido+xfce at berhoerster.name>
Date: Thu Jun 8 11:01:34 2017 +0200
Fix array out of bounds write
- Fix bug #11328
---
panel-plugin/net.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/panel-plugin/net.c b/panel-plugin/net.c
index c66d144..6e8276c 100644
--- a/panel-plugin/net.c
+++ b/panel-plugin/net.c
@@ -35,6 +35,7 @@
#include <libxfce4util/libxfce4util.h>
+
/* From Wormulon */
#include "net.h"
#include "os.h"
@@ -81,8 +82,7 @@ int init_netload(netdata* data, const char* device)
return TRUE;
}
- strncpy( data->ifdata.if_name, device, INTERFACE_NAME_LENGTH);
- data->ifdata.if_name[INTERFACE_NAME_LENGTH] = '\0';
+ g_strlcpy(data->ifdata.if_name, device, sizeof(data->ifdata.if_name));
init_osspecific( data );
--
To stop receiving notification emails like this one, please contact
the administrator of this repository.
More information about the Xfce4-commits
mailing list