[vlc-commits] [Git][videolan/vlc][master] frame: remove padding when using oss-fuzz
Steve Lhomme (@robUx4)
gitlab at videolan.org
Fri Feb 14 14:23:52 UTC 2025
Steve Lhomme pushed to branch master at VideoLAN / VLC
Commits:
124a022f by Thomas Guillem at 2025-02-14T13:50:26+00:00
frame: remove padding when using oss-fuzz
This will cause more realloc when using oss-fuzz but won't hide less than
32 bytes buffer overflow.
- - - - -
1 changed file:
- src/misc/frame.c
Changes:
=====================================
src/misc/frame.c
=====================================
@@ -110,7 +110,11 @@ vlc_frame_t *vlc_frame_Init(vlc_frame_t *restrict f, const struct vlc_frame_call
#define VLC_FRAME_ALIGN 32
/** Initial reserved header and footer size. */
-#define VLC_FRAME_PADDING 32
+#ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
+# define VLC_FRAME_PADDING 0 /* Don't hide buffer overflows */
+#else
+# define VLC_FRAME_PADDING 32 /* Avoid <= 32 bytes reallocs */
+#endif
vlc_frame_t *vlc_frame_Alloc (size_t size)
{
View it on GitLab: https://code.videolan.org/videolan/vlc/-/commit/124a022f103037594dd5dd0df02247996e90ab29
--
View it on GitLab: https://code.videolan.org/videolan/vlc/-/commit/124a022f103037594dd5dd0df02247996e90ab29
You're receiving this email because of your account on code.videolan.org.
VideoLAN code repository instance
More information about the vlc-commits
mailing list