title: AsyncTask status is null
body: <p>In my android app I am using <code>AsyncTask</code>. It was working perfectly but from last 2 days my app crashed when I called .execute() of <code>AsyncTask</code>. The error is:</p>
  
  <pre><code>FATAL EXCEPTION: main
  java.lang.NullPointerException
      at android.os.AsyncTask.execute(AsyncTask.java:378)
      at com.riksof.a320.remote.RemoteObject.update(RemoteObject.java:117)
      at com.fitmo.controller.activity.FitmoEditActivityDetailController.updateActivityDate(FitmoEditActivityDetailController.java:64)
      at com.fitmo.controller.activity.FitmoEditActivityDetailController.access$0(FitmoEditActivityDetailController.java:51)
      at com.fitmo.controller.activity.FitmoEditActivityDetailController$1.onClick(FitmoEditActivityDetailController.java:45)
      at android.view.View.performClick(View.java:2532)
      at android.view.View$PerformClick.run(View.java:9293)
      at android.os.Handler.handleCallback(Handler.java:587)
      at android.os.Handler.dispatchMessage(Handler.java:92)
      at android.os.Looper.loop(Looper.java:143)
      at android.app.ActivityThread.main(ActivityThread.java:4263)
      at java.lang.reflect.Method.invokeNative(Native Method)
      at java.lang.reflect.Method.invoke(Method.java:507)
      at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:839)
      at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:597)
      at dalvik.system.NativeStart.main(Native Method)
  </code></pre>
  
  <p>When I saw the code inside <code>AsyncTask.java</code>, I found this code inside <code>AsyncTask</code> constructor:</p>
  
  <pre><code>switch (mStatus)
  </code></pre>
  
  <p>So I debug the <code>AsyncTask</code> status by calling <code>getStatus()</code> method of <code>AsyncTask</code> before calling <code>execute()</code> and the value is null here as well. What can be the reason for this any ideas ?</p>
  
  <p>I am not getting this every time. Some times it works properly sometimes it doesn't.</p>