[Nagiosplug-checkins] SF.net SVN: nagiosplug: [1907] nagiosplug/trunk
dermoth at users.sourceforge.net
dermoth at users.sourceforge.net
Tue Jan 15 12:34:15 CET 2008
Revision: 1907
http://nagiosplug.svn.sourceforge.net/nagiosplug/?rev=1907&view=rev
Author: dermoth
Date: 2008-01-15 03:34:15 -0800 (Tue, 15 Jan 2008)
Log Message:
-----------
Fix check_disk disk usage calculation when using --group=NAME (related to bug #1348746)
Modified Paths:
--------------
nagiosplug/trunk/NEWS
nagiosplug/trunk/plugins/check_disk.c
Modified: nagiosplug/trunk/NEWS
===================================================================
--- nagiosplug/trunk/NEWS 2008-01-15 09:40:56 UTC (rev 1906)
+++ nagiosplug/trunk/NEWS 2008-01-15 11:34:15 UTC (rev 1907)
@@ -6,6 +6,7 @@
check_dns now sorts addresses for testing results for more than one returned IP (Matthias Urlichs)
Fix segfault in check_ntp_time and (deprecated) check_ntp. (Bug #1862300)
check_disk should now work with large file systems (2TB+) on all archs that supports it
+ Fixed check_disk disk usage calculation when using --group=NAME (related to bug #1348746)
1.4.11 13th December 2007
Fixed check_http regression in 1.4.10 where following redirects to
Modified: nagiosplug/trunk/plugins/check_disk.c
===================================================================
--- nagiosplug/trunk/plugins/check_disk.c 2008-01-15 09:40:56 UTC (rev 1906)
+++ nagiosplug/trunk/plugins/check_disk.c 2008-01-15 11:34:15 UTC (rev 1907)
@@ -265,7 +265,8 @@
(fsp.fsu_blocks + tmpfsp.fsu_blocks); /* Size of a block. */
fsp.fsu_blocks += tmpfsp.fsu_blocks; /* Total blocks. */
fsp.fsu_bfree += tmpfsp.fsu_bfree; /* Free blocks available to superuser. */
- fsp.fsu_bavail += tmpfsp.fsu_bavail; /* Free blocks available to non-superuser. */
+ /* Gnulib workaround - see comment about it a few lines below */
+ fsp.fsu_bavail += (tmpfsp.fsu_bavail > tmpfsp.fsu_bfree ? 0 : tmpfsp.fsu_bavail); /* Free blocks available to non-superuser. */
fsp.fsu_files += tmpfsp.fsu_files; /* Total file nodes. */
fsp.fsu_ffree += tmpfsp.fsu_ffree; /* Free file nodes. */
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
More information about the Commits
mailing list