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
0a4c5edc
Commit
0a4c5edc
authored
Apr 08, 2020
by
Max Kellermann
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'stl' of
git://github.com/neheb/MPD
parents
79e9aff3
015cbff9
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
12 additions
and
36 deletions
+12
-36
FileCommands.cxx
src/command/FileCommands.cxx
+1
-6
InputPlugin.cxx
src/input/InputPlugin.cxx
+2
-5
Cancellable.hxx
src/lib/nfs/Cancellable.hxx
+1
-5
MultipleOutputs.cxx
src/output/MultipleOutputs.cxx
+2
-5
MultipleOutputs.hxx
src/output/MultipleOutputs.hxx
+2
-5
AndSongFilter.cxx
src/song/AndSongFilter.cxx
+3
-5
Builder.cxx
src/tag/Builder.cxx
+1
-5
No files found.
src/command/FileCommands.cxx
View file @
0a4c5edc
...
...
@@ -127,12 +127,7 @@ gcc_pure
static
bool
IsValidValue
(
const
StringView
s
)
noexcept
{
for
(
const
char
ch
:
s
)
{
if
((
unsigned
char
)
ch
<
0x20
)
return
false
;
}
return
true
;
return
std
::
none_of
(
s
.
begin
(),
s
.
end
(),
[](
const
auto
&
ch
)
{
return
(
unsigned
char
)
ch
<
0x20
;
});
}
class
PrintCommentHandler
final
:
public
NullTagHandler
{
...
...
src/input/InputPlugin.cxx
View file @
0a4c5edc
...
...
@@ -33,11 +33,8 @@ InputPlugin::SupportsUri(const char *uri) const noexcept
if
(
StringStartsWithIgnoreCase
(
uri
,
*
i
))
return
true
;
}
else
{
for
(
const
auto
&
schema
:
protocols
())
{
if
(
StringStartsWithIgnoreCase
(
uri
,
schema
.
c_str
())){
return
true
;
}
}
return
std
::
any_of
(
protocols
().
begin
(),
protocols
().
end
(),
[
uri
](
const
auto
&
schema
)
{
return
StringStartsWithIgnoreCase
(
uri
,
schema
.
c_str
());
}
);
}
return
false
;
}
...
...
src/lib/nfs/Cancellable.hxx
View file @
0a4c5edc
...
...
@@ -113,11 +113,7 @@ public:
#ifndef NDEBUG
gcc_pure
bool
IsEmpty
()
const
noexcept
{
for
(
const
auto
&
c
:
list
)
if
(
!
c
.
IsCancelled
())
return
false
;
return
true
;
return
std
::
all_of
(
list
.
begin
(),
list
.
end
(),
[](
const
auto
&
c
)
{
return
c
.
IsCancelled
();
});
}
#endif
...
...
src/output/MultipleOutputs.cxx
View file @
0a4c5edc
...
...
@@ -258,11 +258,8 @@ MultipleOutputs::Open(const AudioFormat audio_format)
bool
MultipleOutputs
::
IsChunkConsumed
(
const
MusicChunk
*
chunk
)
const
noexcept
{
for
(
const
auto
&
ao
:
outputs
)
if
(
!
ao
->
LockIsChunkConsumed
(
*
chunk
))
return
false
;
return
true
;
return
std
::
all_of
(
outputs
.
begin
(),
outputs
.
end
(),
[
chunk
](
const
auto
&
ao
)
{
return
ao
->
LockIsChunkConsumed
(
*
chunk
);
});
}
unsigned
...
...
src/output/MultipleOutputs.hxx
View file @
0a4c5edc
...
...
@@ -28,6 +28,7 @@
#include "Chrono.hxx"
#include "util/Compiler.h"
#include <algorithm>
#include <cassert>
#include <memory>
#include <vector>
...
...
@@ -106,11 +107,7 @@ public:
*/
gcc_pure
bool
IsDummy
()
const
noexcept
{
for
(
const
auto
&
i
:
outputs
)
if
(
!
i
->
IsDummy
())
return
false
;
return
true
;
return
std
::
all_of
(
outputs
.
begin
(),
outputs
.
end
(),
[](
const
auto
&
i
)
{
return
i
->
IsDummy
();
});
}
/**
...
...
src/song/AndSongFilter.cxx
View file @
0a4c5edc
...
...
@@ -19,6 +19,8 @@
#include "AndSongFilter.hxx"
#include <algorithm>
ISongFilterPtr
AndSongFilter
::
Clone
()
const
noexcept
{
...
...
@@ -54,9 +56,5 @@ AndSongFilter::ToExpression() const noexcept
bool
AndSongFilter
::
Match
(
const
LightSong
&
song
)
const
noexcept
{
for
(
const
auto
&
i
:
items
)
if
(
!
i
->
Match
(
song
))
return
false
;
return
true
;
return
std
::
all_of
(
items
.
begin
(),
items
.
end
(),
[
&
song
](
const
auto
&
i
)
{
return
i
->
Match
(
song
);
});
}
src/tag/Builder.cxx
View file @
0a4c5edc
...
...
@@ -154,11 +154,7 @@ TagBuilder::CommitNew() noexcept
bool
TagBuilder
::
HasType
(
TagType
type
)
const
noexcept
{
for
(
auto
i
:
items
)
if
(
i
->
type
==
type
)
return
true
;
return
false
;
return
std
::
any_of
(
items
.
begin
(),
items
.
end
(),
[
type
](
const
auto
&
i
)
{
return
i
->
type
==
type
;
});
}
void
...
...
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