Use POSIX macros for linux

This commit is contained in:
chase
2018-05-24 16:24:41 -05:00
committed by Jon Trulson
parent 164e695cd0
commit 4f5e7fe5e3
265 changed files with 394 additions and 394 deletions

View File

@@ -385,7 +385,7 @@ UtmpEntryCreate(Widget w, pid_t pid, char *utmpLine)
(void) strncpy(utPtr->ut_id, utmpLine,
sizeof(utPtr->ut_id));
#else /* __AIX */
#if defined(linux) || defined(sun)
#if defined(__linux__) || defined(sun)
if (c = strchr(utmpLine, '/')) {
c++;
} else {
@@ -401,7 +401,7 @@ UtmpEntryCreate(Widget w, pid_t pid, char *utmpLine)
/* set up the new entry... */
utPtr->ut_type = USER_PROCESS;
#if !defined(linux)
#if !defined(__linux__)
utPtr->ut_exit.e_termination = 0;
utPtr->ut_exit.e_exit = 2;
#endif
@@ -528,7 +528,7 @@ UtmpEntryDestroy(Widget w, char *utmpLine)
(void) setutent();
if (utPtr = getutline(&ut)) {
utPtr->ut_type = DEAD_PROCESS;
#if !defined(linux)
#if !defined(__linux__)
utPtr->ut_exit.e_termination = 0;
utPtr->ut_exit.e_exit = 0;
#endif