mirror of
https://github.com/owntone/owntone-server.git
synced 2024-12-28 08:05:56 -05:00
Fix handling of URIs in io_open()
Fix io_open()'s handling of options in URI, fixing the "filenames with a question mark are not scanned" bug. Patch by Chris Pitchford, cpitchford on the Firefly forum.
This commit is contained in:
parent
7c1752d871
commit
54d441f57c
7
src/io.c
7
src/io.c
@ -577,16 +577,17 @@ int io_open(IO_PRIVHANDLE *phandle, char *fmt, ...) {
|
|||||||
proto_part = uri_copy;
|
proto_part = uri_copy;
|
||||||
}
|
}
|
||||||
|
|
||||||
if(path_part)
|
|
||||||
io_urldecode(path_part);
|
|
||||||
|
|
||||||
/* find the start of the options */
|
/* find the start of the options */
|
||||||
options_part = strchr(path_part,'?');
|
options_part = strchr(path_part,'?');
|
||||||
if(options_part) {
|
if(options_part) {
|
||||||
*options_part = '\0';
|
*options_part = '\0';
|
||||||
options_part++;
|
options_part++;
|
||||||
|
io_urldecode(options_part);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if(path_part)
|
||||||
|
io_urldecode(path_part);
|
||||||
|
|
||||||
/* see if we can generate a list of options */
|
/* see if we can generate a list of options */
|
||||||
while(options_part) {
|
while(options_part) {
|
||||||
key = options_part;
|
key = options_part;
|
||||||
|
Loading…
Reference in New Issue
Block a user