On Tue, Aug 27, 2024 at 1:51 PM Martin Kletzander <mkletzan(a)redhat.com> wrote:
On Tue, Aug 27, 2024 at 12:08:27PM +0300, Rayhan Faizel wrote:
>
>All the existing code is indeed still compiled as C. Only the fuzzing
>executables (under tests/fuzz/) are compiled in C++ and linked to
>those C objects. We still do need some of the minor code modifications
>(in PATCH 1) because existing C headers are sometimes interpreted a
>bit differently from the fuzzer's PoV, even with C linkage.
>
Sorry, what I meant is whether it would be possible to keep the code as
is, the keyword parameters are a bit of a problem, but writing a layer
of C code to call it through from the C++ code feels weird. Of course
attributes are also complicated to make work, but those changes in the C
code are pretty okay I think.
Sorry, I am not sure I fully understand the first statement regarding
writing a layer of C code. I had only replaced the keyword parameters
with alternative names in PATCH 1.
>There are still some other code modifications in tests/ and src/
for a
>few other fuzzers (mostly hotplug and CH) to make fuzzing easier.
>
>I agree that we could keep it as a separate repo, perhaps a
>subproject. I have seen some projects keep their fuzzing code separate
>(mostly on oss-fuzz).
>
>--
>Rayhan Faizel
>
--
Rayhan Faizel