mirror of https://github.com/google/oss-fuzz.git
fluent-bit: deploy simple fuzz hook in build (#6075)
Signed-off-by: David Korczynski <david@adalogics.com>
This commit is contained in:
parent
0a398c892b
commit
cdeb7f2282
|
@ -14,7 +14,11 @@
|
|||
# limitations under the License.
|
||||
#
|
||||
################################################################################
|
||||
cd fluent-bit/build
|
||||
cd fluent-bit
|
||||
sed -i 's/malloc(/fuzz_malloc(/g' ./lib/msgpack-c/src/zone.c
|
||||
sed -i 's/struct msgpack_zone_chunk {/void *fuzz_malloc(size_t size) {if (size > 0xa00000) return NULL;\nreturn malloc(size);}\nstruct msgpack_zone_chunk {/g' ./lib/msgpack-c/src/zone.c
|
||||
|
||||
cd build
|
||||
|
||||
export CFLAGS="$CFLAGS -fcommon -DFLB_TESTS_OSSFUZZ=ON"
|
||||
export CXXFLAGS="$CXXFLAGS -fcommon -DFLB_TESTS_OSSFUZZ=ON"
|
||||
|
|
Loading…
Reference in New Issue