History

fuzzer_set_property: force untimed and pause state

We don't want to accidentally set those options and timeout in pause state. Remove video-osd as there is no reason to set it in fact.

Kacper Michajłow committed 2 years ago

Commit ee2be6d1 parent c194f2d1 file · +9 −8Browse files

Unified · Split

fuzzers/fuzzer_set_property.c+9−8
@@ -63,20 +63,21 @@ int LLVMFuzzerTestOneInput(const uint8_t *data, size_t size) · 62 unmodified lines
6363 #if MPV_RUN
6464 check_error(mpv_set_option_string(ctx, "vo", "null"));
6565 check_error(mpv_set_option_string(ctx, "ao", "null"));
66− check_error(mpv_set_option_string(ctx, "ao-null-untimed", "yes"));
67− check_error(mpv_set_option_string(ctx, "untimed", "yes"));
68− check_error(mpv_set_option_string(ctx, "video-osd", "no"));
6966
7067 check_error(mpv_initialize(ctx));
7168 #endif
7269
73−if (MPV_FORMAT == MPV_FORMAT_STRING) {
74− mpv_set_property_string(ctx, name, (void *)data);
75−} else {
76− mpv_set_property(ctx, name, MPV_FORMAT, (void *)data);
77−}
70+ if (MPV_FORMAT == MPV_FORMAT_STRING) {
71+ mpv_set_property_string(ctx, name, (void *)data);
72+ } else {
73+ mpv_set_property(ctx, name, MPV_FORMAT, (void *)data);
74+ }
7875
7976 #if MPV_RUN
77+ check_error(mpv_set_option_string(ctx, "ao-null-untimed", "yes"));
78+ check_error(mpv_set_option_string(ctx, "untimed", "yes"));
79+ check_error(mpv_set_option_string(ctx, "pause", "no"));
80+
8081 check_error(mpv_set_option_string(ctx, "audio-files", "av://lavfi:sine=d=0.1"));
8182 const char *cmd[] = {"loadfile", "av://lavfi:yuvtestsrc=d=0.1", NULL};
8283 check_error(mpv_command(ctx, cmd));

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t