Fix issue #2492387: system server crash in WallpaperManagerService
Also move some of the important framework error logs over to Slog.
Change-Id: If6697c3e4f18498612ebd7b0e4e4f042fd713372
diff --git a/services/java/com/android/server/WallpaperManagerService.java b/services/java/com/android/server/WallpaperManagerService.java
index 1b51741..f4bdd1f 100644
--- a/services/java/com/android/server/WallpaperManagerService.java
+++ b/services/java/com/android/server/WallpaperManagerService.java
@@ -340,6 +340,12 @@
final long ident = Binder.clearCallingIdentity();
try {
bindWallpaperComponentLocked(null);
+ } catch (IllegalArgumentException e) {
+ // This can happen if the default wallpaper component doesn't
+ // exist. This should be a system configuration problem, but
+ // let's not let it crash the system and just live with no
+ // wallpaper.
+ Slog.e(TAG, "Default wallpaper component not found!", e);
} finally {
Binder.restoreCallingIdentity(ident);
}