Krolyxon
Commit 915a7fd

Branches

Refs →

nsxiv915a7fd

switch -0 to bottom in options.c

Author
NRK
Date
2021-09-22 02:33 +0600
Committer
Berke Kocaoğlu · 2021-09-21 23:37 +0300
Parent
09d4b70
Commit
915a7fd384e700dff10f6014167764cd9812badd

+6 −6

1 file changed

  1. M options.c +6 −6
M options.c View
@@ -31,7 +31,7 @@ const opt_t *options = (const opt_t*) &_options;
3131
3232 void print_usage(void)
3333 {
34− printf("usage: nsxiv [-abcfhi0opqrtvZ] [-A FRAMERATE] [-e WID] [-G GAMMA] "
34+ printf("usage: nsxiv [-abcfhiopqrtvZ0] [-A FRAMERATE] [-e WID] [-G GAMMA] "
3535 "[-g GEOMETRY] [-N NAME] [-T TITLE] [-n NUM] [-S DELAY] [-s MODE] "
3636 "[-z ZOOM] FILES...\n");
3737 }
@@ -76,7 +76,7 @@ void parse_options(int argc, char **argv)
7676 _options.clean_cache = false;
7777 _options.private_mode = false;
7878
79− while ((opt = getopt(argc, argv, "A:abce:fG:g:hin:N:0opqrS:s:T:tvZz:")) != -1) {
79+ while ((opt = getopt(argc, argv, "A:abce:fG:g:hin:N:opqrS:s:T:tvZz:0")) != -1) {
8080 switch (opt) {
8181 case '?':
8282 print_usage();
@@ -129,10 +129,6 @@ void parse_options(int argc, char **argv)
129129 case 'N':
130130 _options.res_name = optarg;
131131 break;
132− case '0':
133− _options.stdout_separator = '\0';
134− /* -0 implies -o */
135− /* fall through */
136132 case 'o':
137133 _options.to_stdout = true;
138134 break;
@@ -184,6 +180,10 @@ void parse_options(int argc, char **argv)
184180 _options.scalemode = SCALE_ZOOM;
185181 _options.zoom = (float) n / 100.0;
186182 break;
183+ case '0':
184+ _options.stdout_separator = '\0';
185+ _options.to_stdout = true; /* -0 implies -o */
186+ break;
187187 }
188188 }
189189