diff options
| author | jvoisin | 2024-06-14 19:46:14 +0200 |
|---|---|---|
| committer | Julien Voisin | 2024-06-15 13:46:35 +0000 |
| commit | 520e7e4a631cc038b3e867b2255235da35a98ece (patch) | |
| tree | a1ba19a16d1940092334d7df463868f1cfa5e014 /include | |
| parent | 6939e3382a232d20882c1c7e74274132de154bb6 (diff) | |
Fix some pointer-arithmetic warnings
This should fix the second part of #59
Diffstat (limited to 'include')
| -rw-r--r-- | include/fortify-headers.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/include/fortify-headers.h b/include/fortify-headers.h index 796fd2d..f7d8af8 100644 --- a/include/fortify-headers.h +++ b/include/fortify-headers.h | |||
| @@ -141,8 +141,8 @@ | |||
| 141 | * since gcc seems to like to generate code that relies on dst == src */ | 141 | * since gcc seems to like to generate code that relies on dst == src */ |
| 142 | #define __fh_overlap(a, len_a, b, len_b) \ | 142 | #define __fh_overlap(a, len_a, b, len_b) \ |
| 143 | ( \ | 143 | ( \ |
| 144 | ((a) < (b) && (b) < ((a) + (__fh_size_t)(len_a))) \ | 144 | ((char*)(a) < (char*)(b) && (char*)(b) < ((char*)(a) + (__fh_size_t)(len_a))) \ |
| 145 | || ((b) < (a) && (a) < ((b) + (__fh_size_t)(len_b))) \ | 145 | || ((char*)(b) < (char*)(a) && (char*)(a) < ((char*)(b) + (__fh_size_t)(len_b))) \ |
| 146 | ) | 146 | ) |
| 147 | 147 | ||
| 148 | /* | 148 | /* |
