[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [Xen-devel] [PATCH v3 01/12] fuzz/x86_emulate: Clear errors after each iteration
>>> On 10.10.17 at 19:22, <ian.jackson@xxxxxxxxxxxxx> wrote: > George Dunlap writes ("[PATCH v3 01/12] fuzz/x86_emulate: Clear errors after > each iteration"): >> Once feof() returns true for a stream, it will continue to return true >> for that stream until clearerr() is called (or the stream is closed >> and re-opened). >> >> In llvm-clang-fast-mode, the same file descriptor is used for each >> iteration of the loop, meaning that the "Input too large" check was >> broken -- feof() would return true even if the fread() hadn't hit the >> end of the file. The result is that AFL generates testcases of >> arbitrary size. >> >> Fix this by fseek'ing to the beginning of the file on every iteration; >> this resets the EOF marker and other state. > > Acked-by: Ian Jackson <ian.jackson@xxxxxxxxxxxxx> > >> This is a candidate for backport to 4.9. > > Please let me know when it is committed and I will add it to my > backport list. I have the original one on mine already, so I can easily add this one then as well; perhaps I would want to even fold the two into just a single (good) commit). Jan _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxx https://lists.xen.org/xen-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |