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

Commit 1ebebfd9 authored by Martijn Coenen's avatar Martijn Coenen Committed by Alistair Delva
Browse files

Don't crash system_server if fixupAppDir() fails.

Reason why it fails TBD, but either way system_server shouldn't crash.

Bug: 149975102
Test: no crash
Change-Id: Iee3b8a66663179030dd7313ec68e72666b2000f0
parent b629d69d
Loading
Loading
Loading
Loading
+5 −2
Original line number Diff line number Diff line
@@ -4458,8 +4458,11 @@ class StorageManagerService extends IStorageManager.Stub
                    mVold.fixupAppDir(packageObbDir.getCanonicalPath() + "/", uid);
                } catch (IOException e) {
                    Log.e(TAG, "Failed to get canonical path for " + packageName);
                } catch (RemoteException e) {
                    Log.e(TAG, "Failed to fixup app dir for " + packageName);
                } catch (RemoteException | ServiceSpecificException e) {
                    // TODO(b/149975102) there is a known case where this fails, when a new
                    // user is setup and we try to fixup app dirs for some existing apps.
                    // For now catch the exception and don't crash.
                    Log.e(TAG, "Failed to fixup app dir for " + packageName, e);
                }
            }
        }