diff options
Diffstat (limited to 'plugins')
-rw-r--r-- | plugins/converter/converter.c | 10 |
1 files changed, 3 insertions, 7 deletions
diff --git a/plugins/converter/converter.c b/plugins/converter/converter.c index 4da5f327..2d7e8230 100644 --- a/plugins/converter/converter.c +++ b/plugins/converter/converter.c @@ -667,7 +667,9 @@ get_output_field (DB_playItem_t *it, const char *field, char *out, int sz) { int idx = deadbeef->pl_get_idx_of (it); char temp[PATH_MAX]; - deadbeef->pl_format_title (it, idx, temp, sizeof (temp), -1, field); + char fmt[strlen(field)+3]; + snprintf (fmt, sizeof (fmt), "%%/%s", field); + deadbeef->pl_format_title (it, idx, temp, sizeof (temp), -1, fmt); // escape special chars char invalid[] = "$\"`\\"; @@ -681,12 +683,6 @@ get_output_field (DB_playItem_t *it, const char *field, char *out, int sz) *p++ = *t; n--; } - else if (*t == '/') { - *p++ = '\\'; - n--; - *p++ = '\\'; - n--; - } else { *p++ = *t; n--; |