Skip to content

Commit 7a2cb35

Browse files
author
George Mount
committed
Fix monkey NPE in AutoCompletePopup
Bug 6554866 Change-Id: I2942e55d98bc768f5c5c563240c1841c7e869b3c
1 parent 82b3b1b commit 7a2cb35

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

core/java/android/webkit/AutoCompletePopup.java

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -181,8 +181,11 @@ public void onItemClick(AdapterView<?> parent, View view, int position, long id)
181181
// There is no autofill profile setup yet and the user has
182182
// elected to try and set one up. Call through to the
183183
// embedder to action that.
184-
mWebView.getWebChromeClient().setupAutoFill(
184+
WebChromeClient webChromeClient = mWebView.getWebChromeClient();
185+
if (webChromeClient != null) {
186+
webChromeClient.setupAutoFill(
185187
mHandler.obtainMessage(AUTOFILL_FORM));
188+
}
186189
}
187190
} else {
188191
Object selectedItem;

0 commit comments

Comments
 (0)