diff options
author | Mattias Falk <mattias.falk@sonyericsson.com> | 2010-08-26 09:02:30 -0700 |
---|---|---|
committer | Android Git Automerger <android-git-automerger@android.com> | 2010-08-26 09:02:30 -0700 |
commit | 399c6b8ec5b4fda71bbf67edd7e9dcb7fb5b8f00 (patch) | |
tree | 63db1fc2e048cccd6b949cbfd3f0c6011a45ab37 /src/com | |
parent | d90e9e004c74bd049339a3961b109d2055be1cb3 (diff) | |
parent | 552751ea92828f8b78b71533dbba70aa7c316d9d (diff) | |
download | packages_apps_Browser-399c6b8ec5b4fda71bbf67edd7e9dcb7fb5b8f00.zip packages_apps_Browser-399c6b8ec5b4fda71bbf67edd7e9dcb7fb5b8f00.tar.gz packages_apps_Browser-399c6b8ec5b4fda71bbf67edd7e9dcb7fb5b8f00.tar.bz2 |
am 552751ea: Avoid crash in browser in systems with no search provider
Merge commit '552751ea92828f8b78b71533dbba70aa7c316d9d' into gingerbread-plus-aosp
* commit '552751ea92828f8b78b71533dbba70aa7c316d9d':
Avoid crash in browser in systems with no search provider
Diffstat (limited to 'src/com')
-rw-r--r-- | src/com/android/browser/BrowserActivity.java | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/src/com/android/browser/BrowserActivity.java b/src/com/android/browser/BrowserActivity.java index 8db4436..8969296 100644 --- a/src/com/android/browser/BrowserActivity.java +++ b/src/com/android/browser/BrowserActivity.java @@ -629,7 +629,13 @@ public class BrowserActivity extends Activity intent.putExtra(SearchManager.EXTRA_DATA_KEY, extraData); } intent.putExtra(Browser.EXTRA_APPLICATION_ID, getPackageName()); - startActivity(intent); + + // can't be sure there is an activity for the Intent + try { + startActivity(intent); + } catch (ActivityNotFoundException ex) { + return false; + } return true; } |