The open source OpenXR runtime
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

u/process: Make u_process work on non-linux systems

authored by

Julian Petrov and committed by
Jakob Bornecrantz
2e4c857a c7a5a0bc

+13 -12
+13 -12
src/xrt/auxiliary/util/u_process.c
··· 22 22 23 23 #include <errno.h> 24 24 #include <stdbool.h> 25 - #include "u_misc.h" 26 25 #include "u_file.h" 27 26 #include "u_logging.h" 28 27 29 - struct u_process 30 - { 31 - #ifdef XRT_HAVE_LIBBSD 32 - struct pidfh *pfh; 33 - #else 34 - int pid; 35 - #endif 36 - }; 37 - 38 28 XRT_MAYBE_UNUSED static inline int 39 29 get_pidfile_path(char *buf) 40 30 { ··· 45 35 } 46 36 return 0; 47 37 } 38 + 39 + #endif 40 + 41 + #include "u_misc.h" 42 + 43 + struct u_process 44 + { 45 + #ifdef XRT_HAVE_LIBBSD 46 + struct pidfh *pfh; 47 + #else 48 + int pid; 49 + #endif 50 + }; 48 51 49 52 struct u_process * 50 53 u_process_create_if_not_running() ··· 101 104 #endif 102 105 free(proc); 103 106 } 104 - 105 - #endif