Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 79ac873e authored by Chih-hung Hsieh's avatar Chih-hung Hsieh Committed by Automerger Merge Worker
Browse files

Merge "Fix clang-tidy performance-faster-string-find warnings" am: 453028a2

Original change: https://android-review.googlesource.com/c/platform/frameworks/av/+/1233473

Change-Id: Ica43a2e38d18ca0f70ea966a6aedf6ba30fe1e9b
parents 199451eb 453028a2
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -15,7 +15,7 @@ namespace V1_2 {
namespace clearkey {

std::string MemoryFileSystem::GetFileName(const std::string& path) {
    size_t index = path.find_last_of("/");
    size_t index = path.find_last_of('/');
    if (index != std::string::npos) {
        return path.substr(index+1);
    } else {
+1 −1
Original line number Diff line number Diff line
@@ -493,7 +493,7 @@ MediaCodecsXmlParser::Impl::Parser::Parser(State *state, std::string path)
      mPath(path),
      mStatus(NO_INIT) {
    // determine href_base
    std::string::size_type end = path.rfind("/");
    std::string::size_type end = path.rfind('/');
    if (end != std::string::npos) {
        mHrefBase = path.substr(0, end + 1);
    }