[monitoring-plugins] plugins/netutils.h: Adjust UNIX_PATH_MAX for BSD

Holger Weiss git at monitoring-plugins.org
Mon Jul 7 11:40:13 CEST 2014


 Module: monitoring-plugins
 Branch: master
 Commit: a2505f049d48d8ff77159a382f46b3cf854c096d
 Author: Holger Weiss <holger at zedat.fu-berlin.de>
   Date: Mon Jul  7 11:33:39 2014 +0200
    URL: https://www.monitoring-plugins.org/repositories/monitoring-plugins/commit/?id=a2505f0

plugins/netutils.h: Adjust UNIX_PATH_MAX for BSD

On at least FreeBSD, NetBSD, OpenBSD, DragonFly, and OS X, this is
hard-coded at 104 bytes.

Closes #1267.

---

 plugins/netutils.h | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/plugins/netutils.h b/plugins/netutils.h
index c5aa18f..c6fce90 100644
--- a/plugins/netutils.h
+++ b/plugins/netutils.h
@@ -40,8 +40,8 @@
 #ifdef HAVE_SYS_UN_H
 # include <sys/un.h>
 # ifndef UNIX_PATH_MAX
-   /* linux uses this, on sun it's hard-coded at 108 without a define */
-#  define UNIX_PATH_MAX 108
+   /* linux uses this, on sun it's hard-coded at 108 without a define, on BSD at 104 */
+#  define UNIX_PATH_MAX 104
 # endif /* UNIX_PATH_MAX */
 #endif /* HAVE_SYS_UN_H */
 



More information about the Commits mailing list