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

Commit 56b9987e authored by Jakub Adamek's avatar Jakub Adamek
Browse files

Fix idmap calls when a subdir is present.

We need to increase the size of argv so that the last one remains
a NULL.

Bug: 32202741
Change-Id: I6636b5401fa7a61686a48c9a99b3e54e596033f9
parent f58948fc
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -175,7 +175,7 @@ static void verifySystemIdmaps()
                }

                // Generic idmap parameters
                const char* argv[7];
                const char* argv[8];
                int argc = 0;
                struct stat st;

@@ -203,7 +203,7 @@ static void verifySystemIdmaps()
                // Finally, invoke idmap (if any overlay directory exists)
                if (argc > 5) {
                    execv(AssetManager::IDMAP_BIN, (char* const*)argv);
                    ALOGE("failed to execl for idmap: %s", strerror(errno));
                    ALOGE("failed to execv for idmap: %s", strerror(errno));
                    exit(1); // should never get here
                } else {
                    exit(0);