java.lang.NullPointerException: Attempt to invoke virtual method 'java.io.File android.content.Context.getFilesDir()' on a null object reference


Solutions on the web

Solution icon of github
via GitHub by maxme
, 9 months ago
Attempt to invoke virtual method 'java.io.File android.content.Context.getFilesDir()' on a null object reference

Stack trace

java.lang.NullPointerException: Attempt to invoke virtual method 'java.io.File android.content.Context.getFilesDir()' on a null object reference
	at org.wordpress.android.networking.SelfSignedSSLCertsManager.<init>(SelfSignedSSLCertsManager.java:44)
	at org.wordpress.android.networking.SelfSignedSSLCertsManager.getInstance(SelfSignedSSLCertsManager.java:88)
	at org.xmlrpc.android.TrustUserSSLCertsSocketFactory.<init>(TrustUserSSLCertsSocketFactory.java:50)
	at org.xmlrpc.android.XMLRPCClient$ConnectionClient.<init>(XMLRPCClient.java:125)
	at org.xmlrpc.android.XMLRPCClient.instantiateClientForUri(XMLRPCClient.java:146)
	at org.xmlrpc.android.XMLRPCClient.<init>(XMLRPCClient.java:111)
	at org.xmlrpc.android.XMLRPCFactoryDefault.make(XMLRPCFactoryDefault.java:7)
	at org.xmlrpc.android.XMLRPCFactory.instantiate(XMLRPCFactory.java:12)
	at org.xmlrpc.android.ApiHelper$RefreshBlogContentTask.doInBackground(ApiHelper.java:275)
	at org.xmlrpc.android.ApiHelper$RefreshBlogContentTask.doInBackground(ApiHelper.java:232)
	at android.os.AsyncTask$2.call(AsyncTask.java:305)
	at java.util.concurrent.FutureTask.run(FutureTask.java:237)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1133)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:607)
	at java.lang.Thread.run(Thread.java:761)

Write tip

You have a different solution? A short tip here would help you and many other users who saw this issue last week.

Users with the same issue

You are the first who have seen this exception. Write a tip to help other users and build your expert profile.