Skip to content

Commit

Permalink
Merge pull request #1915 from DaveLak/fix-blockers-in-fuzz-diff
Browse files Browse the repository at this point in the history
Instrument test utility functions to increase fuzzer efficiency
  • Loading branch information
Byron authored May 15, 2024
2 parents 4e212c6 + 315a2fd commit adf4bf0
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions fuzzing/fuzz-targets/fuzz_diff.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,16 +17,19 @@
class BytesProcessAdapter:
"""Allows bytes to be used as process objects returned by subprocess.Popen."""

@atheris.instrument_func
def __init__(self, input_string):
self.stdout = io.BytesIO(input_string)
self.stderr = io.BytesIO()

@atheris.instrument_func
def wait(self):
return 0

poll = wait


@atheris.instrument_func
def TestOneInput(data):
fdp = atheris.FuzzedDataProvider(data)

Expand Down

0 comments on commit adf4bf0

Please sign in to comment.