aboutsummaryrefslogtreecommitdiffstats
path: root/pkg/csource/linux_common.go
diff options
context:
space:
mode:
authorDmitry Vyukov <dvyukov@google.com>2017-12-22 11:47:04 +0100
committerDmitry Vyukov <dvyukov@google.com>2017-12-22 11:59:46 +0100
commit3645389673af4c62a636cfe36f258ae770e8fb6b (patch)
tree356f9337e5ca323babef0e43fc345b0017dda798 /pkg/csource/linux_common.go
parent6f298a18e582be006780954d6b0c30cbe2f568f4 (diff)
pkg/csource: fix handling of proc types
Generated program always uses pid=0 even when there are multiple processes. Make each process use own pid. Unfortunately required to do quite significant changes to prog, because the current format only supported fixed pid. Fixes #490
Diffstat (limited to 'pkg/csource/linux_common.go')
-rw-r--r--pkg/csource/linux_common.go1
1 files changed, 1 insertions, 0 deletions
diff --git a/pkg/csource/linux_common.go b/pkg/csource/linux_common.go
index 14a7d91df..5d207bd11 100644
--- a/pkg/csource/linux_common.go
+++ b/pkg/csource/linux_common.go
@@ -8,6 +8,7 @@ var commonHeaderLinux = `
#define _GNU_SOURCE
#endif
+#include <endian.h>
#include <sys/syscall.h>
#include <unistd.h>
#if defined(SYZ_EXECUTOR) || defined(SYZ_THREADED) || defined(SYZ_COLLIDE)