summaryrefslogtreecommitdiffstats
path: root/src/com
diff options
context:
space:
mode:
authorJohn Reck <jreck@google.com>2010-12-21 11:34:12 -0800
committerJohn Reck <jreck@google.com>2010-12-21 11:34:12 -0800
commit991412749b1e0837ab602d77a2264a2186741a05 (patch)
tree6246e0f61c76da0e1f97ff05e460304217961658 /src/com
parentdb49cab0d3e12ec1e99306ef78c7b8d8a2785724 (diff)
downloadpackages_apps_browser-991412749b1e0837ab602d77a2264a2186741a05.zip
packages_apps_browser-991412749b1e0837ab602d77a2264a2186741a05.tar.gz
packages_apps_browser-991412749b1e0837ab602d77a2264a2186741a05.tar.bz2
Fix empty url check
Bug: 3213668 Moved empty check after url fix and trim Change-Id: I79422cae12eefa33db7a970c780db6c0cea16a28
Diffstat (limited to 'src/com')
-rw-r--r--src/com/android/browser/IntentHandler.java3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/com/android/browser/IntentHandler.java b/src/com/android/browser/IntentHandler.java
index e5abb11..ff838f4 100644
--- a/src/com/android/browser/IntentHandler.java
+++ b/src/com/android/browser/IntentHandler.java
@@ -283,11 +283,12 @@ public class IntentHandler {
private static boolean handleWebSearchRequest(Activity activity,
Controller controller, String inUrl, Bundle appData,
String extraData) {
- if (TextUtils.isEmpty(inUrl)) return false;
+ if (inUrl == null) return false;
// In general, we shouldn't modify URL from Intent.
// But currently, we get the user-typed URL from search box as well.
String url = UrlUtils.fixUrl(inUrl).trim();
+ if (TextUtils.isEmpty(url)) return false;
// URLs are handled by the regular flow of control, so
// return early.