Browse Source

If only a disc or track tempate is specified then only disc or track info is printed, respectively.

master
Svend Sorensen 20 years ago
parent
commit
7a0ecb12c2
1 changed files with 14 additions and 2 deletions
  1. +14
    -2
      tools/cueprint.c

+ 14
- 2
tools/cueprint.c View File

@@ -17,8 +17,8 @@
#define T_TEMPLATE "%n: %p \"%t\"\n"

char *progname;
char *d_template = D_TEMPLATE; /* disc template */
char *t_template = T_TEMPLATE; /* track template */
char *d_template = NULL; /* disc template */
char *t_template = NULL; /* track template */

void usage (int status)
{
@@ -362,6 +362,18 @@ int main (int argc, char **argv)
}
}

/* if no disc or track template is set, use the defaults for both */
if (NULL == d_template && NULL == t_template) {
d_template = D_TEMPLATE;
t_template = T_TEMPLATE;
} else {
if (NULL == d_template)
d_template = "";

if (NULL == t_template)
t_template = "";
}

if (optind == argc) {
info("-", format);
} else {


Loading…
Cancel
Save