Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
M
mpd
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Иван Мажукин
mpd
Commits
9f8dc31b
Commit
9f8dc31b
authored
Apr 08, 2020
by
Max Kellermann
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
input/Plugin: copy protocols() to stack before using it
Fixes regression by commit
015cbff9
causing a crash bug because the iterators of two different temporaries were used.
parent
db93bb99
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
1 deletion
+2
-1
InputPlugin.cxx
src/input/InputPlugin.cxx
+2
-1
No files found.
src/input/InputPlugin.cxx
View file @
9f8dc31b
...
@@ -33,7 +33,8 @@ InputPlugin::SupportsUri(const char *uri) const noexcept
...
@@ -33,7 +33,8 @@ InputPlugin::SupportsUri(const char *uri) const noexcept
if
(
StringStartsWithIgnoreCase
(
uri
,
*
i
))
if
(
StringStartsWithIgnoreCase
(
uri
,
*
i
))
return
true
;
return
true
;
}
else
{
}
else
{
return
std
::
any_of
(
protocols
().
begin
(),
protocols
().
end
(),
[
uri
](
const
auto
&
schema
)
const
auto
p
=
protocols
();
return
std
::
any_of
(
p
.
begin
(),
p
.
end
(),
[
uri
](
const
auto
&
schema
)
{
return
StringStartsWithIgnoreCase
(
uri
,
schema
.
c_str
());
}
);
{
return
StringStartsWithIgnoreCase
(
uri
,
schema
.
c_str
());
}
);
}
}
return
false
;
return
false
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment