diff options
Diffstat (limited to 'procps')
-rw-r--r-- | procps/ps.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/procps/ps.c b/procps/ps.c index f84060447..801a6fdf3 100644 --- a/procps/ps.c +++ b/procps/ps.c | |||
@@ -120,13 +120,11 @@ enum { MAX_WIDTH = 2*1024 }; | |||
120 | #if ENABLE_FEATURE_PS_TIME || ENABLE_FEATURE_PS_LONG | 120 | #if ENABLE_FEATURE_PS_TIME || ENABLE_FEATURE_PS_LONG |
121 | static unsigned long get_uptime(void) | 121 | static unsigned long get_uptime(void) |
122 | { | 122 | { |
123 | #ifdef __linux__ | 123 | #if defined __linux__ || ENABLE_PLATFORM_MINGW32 |
124 | struct sysinfo info; | 124 | struct sysinfo info; |
125 | if (sysinfo(&info) < 0) | 125 | if (sysinfo(&info) < 0) |
126 | return 0; | 126 | return 0; |
127 | return info.uptime; | 127 | return info.uptime; |
128 | #elif ENABLE_PLATFORM_MINGW32 | ||
129 | return GetTickCount64()/1000; | ||
130 | #elif 1 | 128 | #elif 1 |
131 | unsigned long uptime; | 129 | unsigned long uptime; |
132 | char buf[sizeof(uptime)*3 + 2]; | 130 | char buf[sizeof(uptime)*3 + 2]; |