Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Disable fuzzer_tool_flac for i386 #749

Merged
merged 1 commit into from
Oct 5, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 5 additions & 1 deletion oss-fuzz/Makefile.am
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,11 @@ EXTRA_DIST = \
noinst_PROGRAMS =

if USE_OSSFUZZERS
noinst_PROGRAMS += fuzzer_encoder fuzzer_encoder_v2 fuzzer_decoder fuzzer_seek fuzzer_metadata fuzzer_reencoder fuzzer_tool_flac fuzzer_tool_metaflac
noinst_PROGRAMS += fuzzer_encoder fuzzer_encoder_v2 fuzzer_decoder fuzzer_seek fuzzer_metadata fuzzer_reencoder fuzzer_tool_metaflac
if FLaC__CPU_IA32
else
noinst_PROGRAMS += fuzzer_tool_flac
endif
endif

fuzzer_encoder_SOURCES = encoder.cc
Expand Down
13 changes: 0 additions & 13 deletions src/flac/encode.c
Original file line number Diff line number Diff line change
Expand Up @@ -1635,12 +1635,6 @@ static void static_metadata_clear(static_metadata_t *m)
static FLAC__bool static_metadata_append(static_metadata_t *m, FLAC__StreamMetadata *d, FLAC__bool needs_delete)
{
void *x;
#ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
#ifdef __i386__
/* Work around i386 ASAN bug */
if(0 == d) return true;
#endif
#endif
if(0 == (x = safe_realloc_nofree_muladd2_(m->metadata, sizeof(*m->metadata), /*times (*/m->num_metadata, /*+*/1/*)*/)))
return false;
m->metadata = (FLAC__StreamMetadata**)x;
Expand Down Expand Up @@ -2920,13 +2914,6 @@ FLAC__bool fskip_ahead(FILE *f, FLAC__uint64 offset)
static uint8_t dump[8192];
struct flac_stat_s stb;

#ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
#ifdef __i386__
/* Work around i386 ASAN bug */
if(offset > (FLAC__uint64)(INT32_MAX)) return false;
#endif
#endif

if(flac_fstat(fileno(f), &stb) == 0 && (stb.st_mode & S_IFMT) == S_IFREG)
{
if(fseeko(f, offset, SEEK_CUR) == 0)
Expand Down
Loading