Deleting an app results in URL schemes from being registered incorrectly

Originator:craig.hockenberry
Number:rdar://6045562 Date Originated:
Status:Open Resolved:
Product: Product Version:
Classification: Reproducible:
 
30-Jun-2008 04:51 PM Craig Hockenberry:
When an application is deleted, it's URL scheme is also unregistered from some internal database. Unfortunately, this can result in a situation where a previously installed application which supports the same URL scheme will no longer be registered in that internal database.

For example, say we have two applications "Alpha" and "Baker" that both support the "foo://" URL scheme. The following sequence of events will result in invalid registration:

1) User installs "Alpha" and happily processes "foo://" URLs with it.

2) User installs "Baker" and it now becomes the application that handles "foo://" URLs.

3) User decides they don't like "Baker" and deletes it.

4) From this point, anytime the user taps on a "foo://" URL, they will see "Unsupported URL" even though "Alpha" is still installed and able to handle "foo://".

"Alpha" should be registered as a valid URL scheme at this point.

The only way to get "Alpha" to be registered is by deleting it and re-installing. This will delete user data in the process.

Duplicates

Number Status Originator Product Title
rdar://7933499 Duplicate/6045562/Closed futuretap iPhone SDK URL handler db not restored after app deletion

Comments

On OS X I use the following to register and update URL schemes:

/ This function adds the designated application and its document and URL claims (if any) to the Launch Services database, making the application a candidate for document and URL binding. / err = LSRegisterURL ((CFURLRef)updateURL, TRUE);

/ This function adds the designated application and its document and URL claims (if any) to the Launch Services database, making the application a candidate for document and URL binding. / err = LSRegisterURL ((CFURLRef)updateURL, TRUE);

Don't know if iPhone has support for it...


Please note: Reports posted here will not necessarily be seen by Apple. All problems should be submitted at bugreport.apple.com before they are posted here. Please only post information for Radars that you have filed yourself, and please do not include Apple confidential information in your posts. Thank you!