We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents 5580e44 + 5d0db4d commit 9de9342Copy full SHA for 9de9342
1 file changed
services/java/com/android/server/MountService.java
@@ -958,6 +958,17 @@ public void shutdown(final IMountShutdownObserver observer) {
958
// Post a unmount message.
959
ShutdownCallBack ucb = new ShutdownCallBack(path, observer);
960
mHandler.sendMessage(mHandler.obtainMessage(H_UNMOUNT_PM_UPDATE, ucb));
961
+ } else if (observer != null) {
962
+ /*
963
+ * Observer is waiting for onShutDownComplete when we are done.
964
+ * Since nothing will be done send notification directly so shutdown
965
+ * sequence can continue.
966
+ */
967
+ try {
968
+ observer.onShutDownComplete(StorageResultCode.OperationSucceeded);
969
+ } catch (RemoteException e) {
970
+ Slog.w(TAG, "RemoteException when shutting down");
971
+ }
972
}
973
974
0 commit comments