projects
/
collectd.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
snmp plugin: Cast the `bitstring' to (char *).
[collectd.git]
/
src
/
snmp.c
diff --git
a/src/snmp.c
b/src/snmp.c
index
6e15a61
..
64f41ad
100644
(file)
--- a/
src/snmp.c
+++ b/
src/snmp.c
@@
-817,7
+817,7
@@
static int csnmp_read_table (struct snmp_session *sess_ptr,
/* Get instance name */
if ((vb->type == ASN_OCTET_STR) || (vb->type == ASN_BIT_STR))
{
/* Get instance name */
if ((vb->type == ASN_OCTET_STR) || (vb->type == ASN_BIT_STR))
{
- strncpy (il->instance, vb->val.bitstring,
+ strncpy (il->instance,
(char *)
vb->val.bitstring,
sizeof (il->instance));
il->instance[sizeof (il->instance) - 1] = '\0';
DEBUG ("Before escape_slashes: %s", il->instance);
sizeof (il->instance));
il->instance[sizeof (il->instance) - 1] = '\0';
DEBUG ("Before escape_slashes: %s", il->instance);