[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Wget-dev] wget2 | Fuzz test fails on 32bit build (with ASAN) (#477)
From: |
Tim Rühsen |
Subject: |
Re: [Wget-dev] wget2 | Fuzz test fails on 32bit build (with ASAN) (#477) |
Date: |
Mon, 30 Sep 2019 15:32:44 +0000 |
Tim Rühsen commented:
What I do see is (seemingly) a wrong pointer comparison:
```
#include <stdio.h>
void main(void) {
char *a=0xf3e0080c;
size_t n=235429897;
printf("%p %p %d\n", a, a + n, a >= (char *)(a + n));
char *b = a + n;
printf("%p %p %d\n", a, b, a >= b);
}
```
Prints out
```
0xf3e0080c 0x1e86815 0
0xf3e0080c 0x1e86815 1
```
The second output is what I expected. Not sure if that is a C specialty. The
`(char *)(a + n)` is a bit explicit - it originally was `a + n`. The check
should find out about pointer overflow.
@darnir Any idea ?
--
Reply to this email directly or view it on GitLab:
https://gitlab.com/gnuwget/wget2/issues/477#note_223993284
You're receiving this email because of your account on gitlab.com.