View Issue Details [ Jump to Notes ] | [ Issue History ] [ Print ] | ||||||||
ID | Project | Category | View Status | Date Submitted | Last Update | ||||
---|---|---|---|---|---|---|---|---|---|
0002871 | NetSurf | [All Projects] General | public | 2024-03-21 07:50 | 2024-04-05 15:15 | ||||
Reporter | xHire | ||||||||
Assigned To | Michael Drake | ||||||||
Severity | crash | Reproducibility | always | ||||||
Status | closed | Resolution | no change required | ||||||
Platform | OS | Gentoo Linux | OS Version | ||||||
Product Version | 3.11 | ||||||||
Target Version | Fixed in Version | ||||||||
Summary | 0002871: Netsurf-gtk crashes on start due to NULL dereference | ||||||||
Description | Netsurf-gtk crashes on start every time. Valgrind (attached) points to a NULL dereference. First I thought the crash was related to libparserutils being updated from 0.2.4 to 0.2.5, but when I rebuild 0.2.4 (or even 0.2.5 without the big change to handling buffers), netsurf still crashes. The stacktrace now shows libhubbub, even though its version hasn’t changed when I ran system update. Still, I tried going a version down (to 0.3.7), but netsurf still crashes and the stacktrace is the same. So I’m not really sure which component is to blame. | ||||||||
Additional Information | I don’t know whether related, but parserutils_buffer_randomise in src/utils/buffer.c (libparserutils) contains a bug, because new chunk of memory is allocated with size `buffer->length`, however, that might be less than `buffer->allocated`, leading to incorrect memory accesses. Otherwise, the changes made in d101b2bb6dc98050f8f1b04d9d2bfeeff5a120c7 (libparserutils) look ok to me. | ||||||||
Tags | No tags attached. | ||||||||
Fixed in CI build # | |||||||||
Reported in CI build # | |||||||||
URL of problem page | |||||||||
Attached Files |
|
Notes | |
xHire (reporter) 2024-03-21 07:51 |
Attaching also the latter valgrind log. |
Michael Drake (administrator) 2024-04-05 14:56 |
It sounds like you have various NetSurf libs installed via your linux package manager? As shared libraries? We don't support that because we won't make any ABI stability guarantees until they hit version 1.0.0. So for now, the libraries aren't currently intended to be used in this way. What I guess might have happened here is that the `struct parserutils_buffer` which added a new member changed the ABI of libparserutils, and any libraries using it (hubbub, libcss, etc) will need to be rebuilt against the updated libparserutils. |
xHire (reporter) 2024-04-05 15:03 |
I think your guess is probably correct. I couldn’t reproduce the crash in an isolated build from git and after a recent rebuild of my system, I can’t reproduce it with system netsurf either. Thank you for your explanation, I’ll be smarter next time. :·) |
Michael Drake (administrator) 2024-04-05 15:14 |
No worries, thanks for letting us know! |
Issue History | |||
Date Modified | Username | Field | Change |
---|---|---|---|
2024-03-21 07:50 | xHire | New Issue | |
2024-03-21 07:50 | xHire | File Added: valgrind.log | |
2024-03-21 07:51 | xHire | File Added: libhubbub-valgrind.log | |
2024-03-21 07:51 | xHire | Note Added: 0002441 | |
2024-04-05 14:56 | Michael Drake | Note Added: 0002442 | |
2024-04-05 15:03 | xHire | Note Added: 0002443 | |
2024-04-05 15:14 | Michael Drake | Note Added: 0002444 | |
2024-04-05 15:15 | Michael Drake | Assigned To | => Michael Drake |
2024-04-05 15:15 | Michael Drake | Status | new => closed |
2024-04-05 15:15 | Michael Drake | Resolution | open => no change required |