Signal-Android icon indicating copy to clipboard operation
Signal-Android copied to clipboard

opening hyperlink with no browser installed crashes TS

Open yawnbox opened this issue 11 years ago • 7 comments

https://gist.github.com/40e0ca458f712207dee7

If I send or receive an HTTP/HTTPS link and try to open said link on a device that has no web browser installed, TextSecure will crash.

yawnbox avatar Jul 19 '15 22:07 yawnbox

No Web browser?

jeremymasters avatar Jul 20 '15 00:07 jeremymasters

Yes, no browser.

"I don’t have a browser like Chrome or Firefox because the web isn’t safe." https://yawnbox.com/?p=2561

Because my goal is to protect my messages and my contacts. But this is beside the point, TS shouldn't crash because of a lack of third party software that has nothing to do with TS.

yawnbox avatar Jul 20 '15 05:07 yawnbox

This behavior happens with the native SMS app on Android as well. Is this something that can be fixed in the TS code or is it a problem with how Android deals with clickables that are formatted as HTTP/S links? I'm not seeing anywhere where the proper Intent is built for the web browser activity in ConversationItem or anywhere else.

junitas avatar Aug 01 '15 21:08 junitas

I can't reproduce this issue, on my phone (UMI ZERO with Android 4.4.2) it just says "No App found for this Action" (or something like this, it actually says "Diese Aktion kann von keiner App ausgeführt werden.")

RalfKeller avatar Aug 16 '15 20:08 RalfKeller

If I understand correctly, for massage display the android class TextView is used. So this class delegates the click on a link to according app. Does it make sense to set linksClickable to False if no browser is detected?

SergejKern avatar Sep 16 '15 08:09 SergejKern

This issue also affects the help button in the conversation list's menu.

FeuRenard avatar Aug 05 '16 21:08 FeuRenard

Those crashes will happen every time you click one of these items:

  • URL but no browser installed
  • phone number but no dialer or contacts app installed
  • email address but no email app installed
  • map address but no map app installed (not tested)

Here is what F-Droid does to check for an installed activity. But its links aren't in a TextView. So no simple copy and paste :disappointed:. Anyway it could be used for the help button.

FeuRenard avatar Aug 05 '16 22:08 FeuRenard