Move macro definitions close to usage

main
Christian Göttsche 5 years ago
parent 1193c6e349
commit 0cb257586a
  1. 4
      Process.h
  2. 5
      linux/LinuxProcess.c

@ -15,10 +15,6 @@ in the source distribution for its full text.
#include "Object.h"
#include "RichString.h"
#ifdef __ANDROID__
#define SYS_ioprio_get __NR_ioprio_get
#define SYS_ioprio_set __NR_ioprio_set
#endif
#define PROCESS_FLAG_IO 0x0001
#define DEFAULT_HIGHLIGHT_SECS 5

@ -184,6 +184,11 @@ static int LinuxProcess_effectiveIOPriority(const LinuxProcess* this) {
return this->ioPriority;
}
#ifdef __ANDROID__
#define SYS_ioprio_get __NR_ioprio_get
#define SYS_ioprio_set __NR_ioprio_set
#endif
IOPriority LinuxProcess_updateIOPriority(LinuxProcess* this) {
IOPriority ioprio = 0;
// Other OSes masquerading as Linux (NetBSD?) don't have this syscall

Loading…
Cancel
Save