summaryrefslogtreecommitdiff
path: root/net/arla/patches/patch-bo
blob: 715eb1333cd49f34138090691459f00bcfcc624d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
$NetBSD: patch-bo,v 1.2 2002/12/23 18:28:20 cjep Exp $

On NetBSD, comment out call to setgetprogname().

--- appl/bos/bos.c.orig	Tue Aug 20 18:23:16 2002
+++ appl/bos/bos.c	Tue Aug 20 18:24:24 2002
@@ -145,9 +145,19 @@
     Log_method *method;
     int ret = 0;
     
+/*
+ * The setprogname(3) function was introduced in NetBSD 1.6.
+ * It is a function provided for compatibility, and in NetBSD,
+ * calling setprogname() from main() has no effect.
+ * In order to for this to work on older NetBSD systems,
+ * we just comment the call to setprogname() out.
+ */
+#if !defined(__NetBSD__) 
     setprogname(argv[0]);
-
     method = log_open (getprogname(), "/dev/stderr:notime");
+#else
+    method = log_open ("bos", "/dev/stderr:notime");
+#endif
     if (method == NULL)
 	errx (1, "log_open failed");
     cell_init(0, method);