[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Wget-dev] wget2 | wget_options_fuzzer sometimes (randomly) hangs du
From: |
Tim Rühsen |
Subject: |
Re: [Wget-dev] wget2 | wget_options_fuzzer sometimes (randomly) hangs during make check (#464) |
Date: |
Mon, 26 Aug 2019 09:13:50 +0000 |
Tim Rühsen commented:
When the process hung, I started gdb with
```
$ ps -ef|grep wget_options_fuzzer
tim 21609 21608 2 10:48 pts/7 00:00:00
/home/tim/src/wget2/fuzz/.libs/wget_options_fuzzer
$ gdb /home/tim/src/wget2/fuzz/.libs/wget_options_fuzzer 21609
(gdb) bt
#5 0x00007f7cecd49feb in _IO_fgets (buf=0x7fff495d44c0 "\200", n=<optimized
out>, fp=0x7f7cece95a00 <_IO_2_1_stdin_>)
at iofgets.c:53
#6 0x000055ffb982d14c in _preload_dns_cache (fname=0x55ffba9910a0 "-") at
options.c:2949
#7 0x000055ffb982f1bb in init (argc=6, argv=0x55ffb9841620 <argv>) at
options.c:3611
#8 0x000055ffb9827e33 in LLVMFuzzerTestOneInput (data=0x55ffba9cfdc0
"dnscachePreload=-", size=17) at wget_options_fuzzer.c:114
#9 0x000055ffb9827f85 in test_all_from (dirname=0x7fff495d47b0
"/usr/oms/src/wget2/fuzz/wget_options_fuzzer.in") at main.c:57
#10 0x000055ffb9828355 in main (argc=1, argv=0x7fff495d49a8) at main.c:117
```
As you can see, it hung in fgets() in function `_preload_dns_cache()`. It was
as I expected, if the filename is "-" we read from STDIN. The fuzzer generated
a corpus with exactly this code path. During testing, config.dontwrite is set -
so I used this to skip STDIN when testing.
What isn't clear to me, why does it sometimes hang and sometimes not. This is
random/unpredictable/flaky behavior of glibc (or underlying layers) - but I
don't have the time to track this down.
--
Reply to this email directly or view it on GitLab:
https://gitlab.com/gnuwget/wget2/issues/464#note_207957945
You're receiving this email because of your account on gitlab.com.