[Xymon] RPMs 4.3.29 - showgraph bug - PATCH

John Horne john.horne at plymouth.ac.uk
Fri Aug 9 13:28:49 CEST 2019


Hi,

Attached is a unified diff patch to the 'web/showgraph.c' file for the
Terabithia RPMs based on version 4.3.29. So if the file hasn't changed in the
4.3.30 branch then it should be okay to just apply it directly.

The patch is only 2 (non-contiguous) lines long. The first line just removes
some redundant maths. Both lines cater for the fact that 'snprintf' is now used
in the code. That function has the unfortunate habit of returning the string
length (say 10 characters), but the provided buffer must be large enough to
hold the string *and* the terminating null character (so 11 characters). In
testing it was found that the string was being truncated by one character
because the terminating null was being forced onto the end. When used with
'exec:' in graph titles, this caused the title to not appear at all.


John.

--
John Horne | Senior Operations Analyst | Technology and Information Services
University of Plymouth | Drake Circus | Plymouth | Devon | PL4 8AA | UK
________________________________
[http://www.plymouth.ac.uk/images/email_footer.gif]<http://www.plymouth.ac.uk/worldclass>

This email and any files with it are confidential and intended solely for the use of the recipient to whom it is addressed. If you are not the intended recipient then copying, distribution or other use of the information contained is strictly prohibited and you should not rely on it. If you have received this email in error please let the sender know immediately and delete it from your system(s). Internet emails are not necessarily secure. While we take every care, University of Plymouth accepts no responsibility for viruses and it is your responsibility to scan emails and their attachments. University of Plymouth does not accept responsibility for any changes made after it was sent. Nothing in this email or its attachments constitutes an order for goods or services unless accompanied by an official order form.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: showgraph.c.patch
Type: text/x-patch
Size: 746 bytes
Desc: showgraph.c.patch
URL: <http://lists.xymon.com/pipermail/xymon/attachments/20190809/aaf575b4/attachment.bin>


More information about the Xymon mailing list