diff options
author | wm4 <wm4@nowhere> | 2015-01-26 11:38:23 +0100 |
---|---|---|
committer | wm4 <wm4@nowhere> | 2015-01-26 11:38:23 +0100 |
commit | 9b8d3acc8b95771de2f2be2d687290f71979e458 (patch) | |
tree | 8f85a29e7db55a7dc81460af1dd832dd9599252c | |
parent | 96f7c96da02c235c0f4511f30ea81c45933bf881 (diff) | |
download | mpv-9b8d3acc8b95771de2f2be2d687290f71979e458.tar.bz2 mpv-9b8d3acc8b95771de2f2be2d687290f71979e458.tar.xz |
options: list correct default value for --screenshot-template
Make the default value part of the option metadata, instead of doing
this in the screenshot code. Makes more sense with --list-options and
the command.c option metadata properties.
-rw-r--r-- | options/options.c | 1 | ||||
-rw-r--r-- | player/screenshot.c | 2 |
2 files changed, 2 insertions, 1 deletions
diff --git a/options/options.c b/options/options.c index 1541f6f323..e5e5975224 100644 --- a/options/options.c +++ b/options/options.c @@ -778,6 +778,7 @@ const struct MPOpts mp_default_opts = { .sub_fix_timing = 1, .sub_cp = "auto", .mkv_subtitle_preroll_secs = 1.0, + .screenshot_template = "shot%n", .hwdec_codecs = "h264,vc1,wmv3", diff --git a/player/screenshot.c b/player/screenshot.c index 702e2dd766..0f0ac72419 100644 --- a/player/screenshot.c +++ b/player/screenshot.c @@ -129,7 +129,7 @@ static char *create_fname(struct MPContext *mpctx, char *template, struct tm *local_time = localtime(&raw_time); if (!template || *template == '\0') - template = "shot%n"; + return NULL; for (;;) { char *next = strchr(template, '%'); |