David Ecker <david.ec...@systeme.de> writes:

> Void debugmsg_hex(const char *token, const u_char * thedata, size_t len)
...
> Caling debugmsg with an character string longer than LOGLENGTH==1024
> will result in the above error message. The error message is printed
> in "int snmp_vlog(int priority, const char *format, va_list ap)"
> snmp_logging.c
>
> Solution?:
>
> Either do not allow sprint_realloc_hexstringto realloc the character
> buffer or check after sprint_realloc_hexstring out_len and truncate
> the result yourself.

> Should I create a patch for this?

Yes please!

I'd truncate it after the returned length was too long...
-- 
Wes Hardaker
Please mail all replies to net-snmp-coders@lists.sourceforge.net

------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and 
threat landscape has changed and how IT managers can respond. Discussions 
will include endpoint security, mobile security and the latest in malware 
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
_______________________________________________
Net-snmp-coders mailing list
Net-snmp-coders@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/net-snmp-coders

Reply via email to