diff --git a/java/src/com/android/inputmethod/compat/InputMethodManagerCompatWrapper.java b/java/src/com/android/inputmethod/compat/InputMethodManagerCompatWrapper.java
index 3bf0ed6b58407d555d98636bb578f837e759bf2d..5e66bf4d9066ed37fde451cb2501bcf3223c3821 100644
--- a/java/src/com/android/inputmethod/compat/InputMethodManagerCompatWrapper.java
+++ b/java/src/com/android/inputmethod/compat/InputMethodManagerCompatWrapper.java
@@ -75,6 +75,9 @@ public class InputMethodManagerCompatWrapper {
             InputMethodInfoCompatWrapper imi, boolean allowsImplicitlySelectedSubtypes) {
         Object retval = CompatUtils.invoke(mImm, null, METHOD_getEnabledInputMethodSubtypeList,
                 (imi != null ? imi.getInputMethodInfo() : null), allowsImplicitlySelectedSubtypes);
+        // Returns an empty list
+        if (retval == null)
+            return Collections.emptyList();
         return CompatUtils.copyInputMethodSubtypeListToWrapper((List<?>)retval);
     }