about summary refs log tree commit diff
path: root/linuxthreads/Examples/ex17.c
diff options
context:
space:
mode:
Diffstat (limited to 'linuxthreads/Examples/ex17.c')
-rw-r--r--linuxthreads/Examples/ex17.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/linuxthreads/Examples/ex17.c b/linuxthreads/Examples/ex17.c
index bedf86806f..f5c99ee3fb 100644
--- a/linuxthreads/Examples/ex17.c
+++ b/linuxthreads/Examples/ex17.c
@@ -28,7 +28,7 @@ main (void)
 		PROT_READ | PROT_WRITE | PROT_EXEC,
 		MAP_PRIVATE | MAP_ANONYMOUS, -1, 0);
 
-  if (stack == (void *)-1)
+  if (stack == MAP_FAILED)
     {
       perror ("mmap failed");
       return 1;