Skip to content

Commit

Permalink
add missing <unistd.h>
Browse files Browse the repository at this point in the history
Fixes compile error with gcc 14:
```text
glibc_2.23/mmap_overlapping_chunks.c: In function ‘main’:
glibc_2.23/mmap_overlapping_chunks.c:142:9: error: implicit declaration of function ‘_exit’; did you mean ‘_Exit’? [-Wimplicit-function-declaration]
  142 |         _exit(0); // exit early just in case we corrupted some libraries
      |         ^~~~~
      |         _Exit
```
  • Loading branch information
Xeonacid committed Nov 18, 2024
1 parent df12766 commit 7989de3
Show file tree
Hide file tree
Showing 12 changed files with 12 additions and 0 deletions.
1 change: 1 addition & 0 deletions glibc_2.23/mmap_overlapping_chunks.c
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
#include <stdlib.h>
#include <stdio.h>
#include <assert.h>
#include <unistd.h>

/*
Technique should work on all versions of GLibC
Expand Down
1 change: 1 addition & 0 deletions glibc_2.24/mmap_overlapping_chunks.c
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
#include <stdlib.h>
#include <stdio.h>
#include <assert.h>
#include <unistd.h>

/*
Technique should work on all versions of GLibC
Expand Down
1 change: 1 addition & 0 deletions glibc_2.27/mmap_overlapping_chunks.c
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
#include <stdlib.h>
#include <stdio.h>
#include <assert.h>
#include <unistd.h>

/*
Technique should work on all versions of GLibC
Expand Down
1 change: 1 addition & 0 deletions glibc_2.31/mmap_overlapping_chunks.c
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
#include <stdlib.h>
#include <stdio.h>
#include <assert.h>
#include <unistd.h>

/*
Technique should work on all versions of GLibC
Expand Down
1 change: 1 addition & 0 deletions glibc_2.32/mmap_overlapping_chunks.c
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
#include <stdlib.h>
#include <stdio.h>
#include <assert.h>
#include <unistd.h>

/*
Technique should work on all versions of GLibC
Expand Down
1 change: 1 addition & 0 deletions glibc_2.33/mmap_overlapping_chunks.c
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
#include <stdlib.h>
#include <stdio.h>
#include <assert.h>
#include <unistd.h>

/*
Technique should work on all versions of GLibC
Expand Down
1 change: 1 addition & 0 deletions glibc_2.34/mmap_overlapping_chunks.c
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
#include <stdlib.h>
#include <stdio.h>
#include <assert.h>
#include <unistd.h>

/*
Technique should work on all versions of GLibC
Expand Down
1 change: 1 addition & 0 deletions glibc_2.35/mmap_overlapping_chunks.c
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
#include <stdlib.h>
#include <stdio.h>
#include <assert.h>
#include <unistd.h>

/*
Technique should work on all versions of GLibC
Expand Down
1 change: 1 addition & 0 deletions glibc_2.36/mmap_overlapping_chunks.c
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
#include <stdlib.h>
#include <stdio.h>
#include <assert.h>
#include <unistd.h>

/*
Technique should work on all versions of GLibC
Expand Down
1 change: 1 addition & 0 deletions glibc_2.37/mmap_overlapping_chunks.c
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
#include <stdlib.h>
#include <stdio.h>
#include <assert.h>
#include <unistd.h>

/*
Technique should work on all versions of GLibC
Expand Down
1 change: 1 addition & 0 deletions glibc_2.38/mmap_overlapping_chunks.c
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
#include <stdlib.h>
#include <stdio.h>
#include <assert.h>
#include <unistd.h>

/*
Technique should work on all versions of GLibC
Expand Down
1 change: 1 addition & 0 deletions glibc_2.39/mmap_overlapping_chunks.c
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
#include <stdlib.h>
#include <stdio.h>
#include <assert.h>
#include <unistd.h>

/*
Technique should work on all versions of GLibC
Expand Down

0 comments on commit 7989de3

Please sign in to comment.