diff options
author | Robin Sonefors <robin.sonefors@op5.com> | 2013-01-23 18:10:55 (GMT) |
---|---|---|
committer | Sven Nierlein <sven@nierlein.de> | 2013-01-23 18:52:24 (GMT) |
commit | 77eba263610bb9f85fa9fadf0df39b15bc1919ff (patch) | |
tree | d5415131a0a989edad83195b666dcb0d77163036 /config.rpath | |
parent | 1845c4cdf98fe9cf4bc95b6e11ae94cec1dcd4cc (diff) | |
download | monitoring-plugins-77eba263610bb9f85fa9fadf0df39b15bc1919ff.tar.gz |
check_snmp: Don't thrash memory when using multiple label/unit argument
The memory allocation mixed up number of bytes with number of pointers,
meaning as soon as we'd reach (on 64 bit systems) the second argument,
we'd start writing it outside of our allocated memory.
Normally, this isn't too visible, but as soon as you (again, on my 64
bit system) reach argument number 8, you get a segfault. It is easily
reproducible with:
check_snmp -o '' -l '' -o '' -l '' -o '' -l '' -o '' -l '' \
-o '' -l '' -o '' -l '' -o '' -l '' -o '' -l ''
This patch allocates the proper amount of memory, to fix the issue.
Signed-off-by: Robin Sonefors <robin.sonefors@op5.com>
Diffstat (limited to 'config.rpath')
0 files changed, 0 insertions, 0 deletions