diff options
author | Max Kellermann <max@musicpd.org> | 2020-04-03 15:41:09 +0200 |
---|---|---|
committer | Max Kellermann <max@musicpd.org> | 2020-04-03 16:13:15 +0200 |
commit | 91c75a133f25d2b447391351c59b0e07e69c9ed1 (patch) | |
tree | c78ca0cc53db5d73bc384b6f303919eb30c30e3a /src/db/plugins/simple | |
parent | e620677d7ce133214809dccd29c7cec13a34716b (diff) |
lib/icu/Collate: pass std::string_view
Diffstat (limited to 'src/db/plugins/simple')
-rw-r--r-- | src/db/plugins/simple/Directory.cxx | 2 | ||||
-rw-r--r-- | src/db/plugins/simple/SongSort.cxx | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/src/db/plugins/simple/Directory.cxx b/src/db/plugins/simple/Directory.cxx index 56eaa3877..4c4522622 100644 --- a/src/db/plugins/simple/Directory.cxx +++ b/src/db/plugins/simple/Directory.cxx @@ -199,7 +199,7 @@ gcc_pure static bool directory_cmp(const Directory &a, const Directory &b) noexcept { - return IcuCollate(a.path.c_str(), b.path.c_str()) < 0; + return IcuCollate(a.path, b.path) < 0; } void diff --git a/src/db/plugins/simple/SongSort.cxx b/src/db/plugins/simple/SongSort.cxx index 0aa41b882..4f38384f4 100644 --- a/src/db/plugins/simple/SongSort.cxx +++ b/src/db/plugins/simple/SongSort.cxx @@ -96,7 +96,7 @@ song_cmp(const Song &a, const Song &b) noexcept return ret < 0; /* still no difference? compare file name */ - return IcuCollate(a.filename.c_str(), b.filename.c_str()) < 0; + return IcuCollate(a.filename, b.filename) < 0; } void |