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

Commit 0756fae4 authored by Dimitry Ivanov's avatar Dimitry Ivanov Committed by Gerrit Code Review
Browse files

Merge "Check if public namespace has already been initialized"

parents 3fb5f138 80ddb8f5
Loading
Loading
Loading
Loading
+7 −0
Original line number Original line Diff line number Diff line
@@ -117,6 +117,13 @@ class LibraryNamespaces {
  }
  }


  void Initialize() {
  void Initialize() {
    // Once public namespace is initialized there is no
    // point in running this code - it will have no effect
    // on the current list of public libraries.
    if (initialized_) {
      return;
    }

    std::vector<std::string> sonames;
    std::vector<std::string> sonames;
    const char* android_root_env = getenv("ANDROID_ROOT");
    const char* android_root_env = getenv("ANDROID_ROOT");
    std::string root_dir = android_root_env != nullptr ? android_root_env : "/system";
    std::string root_dir = android_root_env != nullptr ? android_root_env : "/system";