title: Android - Null pointer execute() & DialogProgress AsyncTask
body: <p>I have this code below that basically is the Login process of my app, Why do i have null pointers? Have I implemented it correctly, I have tried to use static for AsyncTask to avoid any memoryleak.</p>
  
  <p>Login.java</p>
  
  <pre><code>    if (handler.executeLog(username.trim(), password.trim())) {
          session.saveLogin(username, password);
          Toast.makeText(this, "Successfully Logged In", Toast.LENGTH_SHORT).show();
          Intent log = new Intent(this, MainActivity.class);
          startActivity(log);
          handler.close();
          finish();
  </code></pre>