aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--tests/dristat.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/tests/dristat.c b/tests/dristat.c
index cb91132e..89853164 100644
--- a/tests/dristat.c
+++ b/tests/dristat.c
@@ -131,7 +131,7 @@ static void getclients(int fd)
for (i = 0; !drmGetClient(fd, i, &auth, &pid, &uid, &magic, &iocs); i++) {
sprintf(buf, "/proc/%d/cmdline", pid);
- memset(cmd, sizeof(cmd), 0);
+ memset(cmd, 0, sizeof(cmd));
if ((procfd = open(buf, O_RDONLY, 0)) >= 0) {
read(procfd, cmd, sizeof(cmd)-1);
close(procfd);