I'm trying to use AccountManager to store account information and have implemented an authenticator, but I keep getting exceptions like the below that crash the phone. Comparing with sample code this seems to be because I don't have (or particularly want) a SyncAdapter and associated service. Is there a trick to using AccountManager without adding a SyncAdapter?
Regards
Phil
I/AuthenticatorActivity( 8526): onAuthenticationResult(true)
I/AuthenticatorActivity( 8526): finishLogin()
W/dalvikvm( 8108): threadid=13: thread exiting with uncaught exception (group=0x
4001b170)
E/AndroidRuntime( 8108): Uncaught handler: thread android.server.ServerThread ex
iting due to uncaught exception
E/AndroidRuntime( 8108): *** EXCEPTION IN SYSTEM PROCESS. System will crash.
E/AndroidRuntime( 8108): java.lang.NullPointerException
E/AndroidRuntime( 8108): at com.android.settings.ManageAccountsSettings.o
nSyncStateUpdated(ManageAccountsSettings.java:187)
E/AndroidRuntime( 8108): at com.android.settings.ManageAccountsSettings.o
nAccountsUpdated(ManageAccountsSettings.java:244)
E/AndroidRuntime( 8108): at android.accounts.AccountManager$10.run(Accoun
tManager.java:826)
E/AndroidRuntime( 8108): at android.os.Handler.handleCallback(Handler.jav
a:587)
E/AndroidRuntime( 8108): at android.os.Handler.dispatchMessage(Handler.ja
va:92)
E/AndroidRuntime( 8108): at android.os.Looper.loop(Looper.java:123)
E/AndroidRuntime( 8108): at com.android.server.ServerThread.run(SystemSer
ver.java:435)