chiark / gitweb /
libuv: Update from 1.20.0 to 1.20.1
[termux-packages] / packages / screen / utmp.c.patch
1 --- ../cache/screen-4.4.0/utmp.c        2016-06-19 19:41:03.000000000 +0000
2 +++ ./utmp.c    2016-12-20 04:10:53.775426042 +0000
3 @@ -33,11 +33,13 @@
4  #include "config.h"
5  #include "screen.h"
6  #include "extern.h"
7 -
8 +#include "os.h"
9  #ifdef HAVE_UTEMPTER
10  #include <utempter.h>
11  #endif
12 -
13 +#ifdef __ANDROID__
14 +#define DEAD_PROCESS 8
15 +#endif
16  
17  extern struct display *display;
18  #ifdef CAREFULUTMP
19 @@ -94,11 +96,12 @@
20  static int  initutmp __P((void));
21  static void setutent __P((void));
22  #endif
23 +#ifndef __ANDROID__
24  #if defined(linux) && defined(GETUTENT)
25  static struct utmp *xpututline __P((struct utmp *utmp));
26  # define pututline xpututline
27  #endif
28 -
29 +#endif
30  
31  static int utmpok;
32  static char UtmpName[] = UTMPFILE;
33 @@ -558,7 +561,6 @@
34    bzero((char *)&u, sizeof(u));
35    strncpy(u.ut_line, slot, sizeof(u.ut_line));
36    setutent();
37 -  return getutline(&u);
38  }
39  
40  static int
41 @@ -872,7 +874,7 @@
42    return *retbuf ? retbuf : NULL;
43  }
44  # endif /* BUGGYGETLOGIN */
45 -
46 +#ifndef __ANDROID__
47  #if defined(linux) && defined(GETUTENT)
48  # undef pututline
49  
50 @@ -890,4 +892,5 @@
51    return u->ut_type == u2->ut_type ? u : 0;
52  }
53  #endif
54 +#endif
55