summaryrefslogtreecommitdiff
path: root/procps-ng/musl-fixes.patch
blob: dd599cf215b55a97eb08a1acdc57b6092814a691 (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
28
29
Pulling in utmpx.h which does not have UT_HOSTSIZE, UT_LINESIZE & UT_NAMESIZE defined.

Causing:
w.c: In function 'print_from':
w.c:236:43: error: 'UT_HOSTSIZE' undeclared (first use in this function)
  236 |    print_display_or_interface(u->ut_host, UT_HOSTSIZE, fromlen - len);
      |                                           ^~~~~~~~~~~
w.c:236:43: note: each undeclared identifier is reported only once for each function it appears in
w.c: In function 'getproc':
w.c:357:12: error: 'UT_NAMESIZE' undeclared (first use in this function)
  357 |   char buf[UT_NAMESIZE + 1];
....
diff --git a/src/w.c b/src/w.c
index 5e878f0..568db02 100644
--- a/src/w.c
+++ b/src/w.c
@@ -46,11 +46,7 @@
 #include <termios.h>
 #include <time.h>
 #include <unistd.h>
-#ifdef HAVE_UTMPX_H
-#	include <utmpx.h>
-#else
-#	include <utmp.h>
-#endif
+#include <utmp.h>
 #include <arpa/inet.h>
 
 #include "c.h"