aboutsummaryrefslogtreecommitdiffstats
path: root/tools/perf/util/usage.c
diff options
context:
space:
mode:
Diffstat (limited to 'tools/perf/util/usage.c')
-rw-r--r--tools/perf/util/usage.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/tools/perf/util/usage.c b/tools/perf/util/usage.c
index d0c013934f30..52bb07c6442a 100644
--- a/tools/perf/util/usage.c
+++ b/tools/perf/util/usage.c
@@ -83,7 +83,7 @@ void warning(const char *warn, ...)
83 va_end(params); 83 va_end(params);
84} 84}
85 85
86uid_t parse_target_uid(const char *str, pid_t tid, pid_t pid) 86uid_t parse_target_uid(const char *str, const char *tid, const char *pid)
87{ 87{
88 struct passwd pwd, *result; 88 struct passwd pwd, *result;
89 char buf[1024]; 89 char buf[1024];
@@ -91,8 +91,8 @@ uid_t parse_target_uid(const char *str, pid_t tid, pid_t pid)
91 if (str == NULL) 91 if (str == NULL)
92 return UINT_MAX; 92 return UINT_MAX;
93 93
94 /* CPU and PID are mutually exclusive */ 94 /* UID and PID are mutually exclusive */
95 if (tid > 0 || pid > 0) { 95 if (tid || pid) {
96 ui__warning("PID/TID switch overriding UID\n"); 96 ui__warning("PID/TID switch overriding UID\n");
97 sleep(1); 97 sleep(1);
98 return UINT_MAX; 98 return UINT_MAX;