diff --git a/src/com/savoirfairelinux/sflphone/client/CallActivity.java b/src/com/savoirfairelinux/sflphone/client/CallActivity.java
index 9b11152f8cef64e10399e86d1745f844933c2f22..4bf65b7189cc24a25418209dc67f6533912a67d9 100644
--- a/src/com/savoirfairelinux/sflphone/client/CallActivity.java
+++ b/src/com/savoirfairelinux/sflphone/client/CallActivity.java
@@ -127,7 +127,9 @@ public class CallActivity extends Activity implements OnClickListener
                 mCall.notifyServiceAnswer(service);
                 break;
             case R.id.buttonhangup:
-                if(mCall.getCallStateInt() == SipCall.CALL_STATE_CURRENT) {
+                if((mCall.getCallStateInt() == SipCall.CALL_STATE_NONE) ||
+                   (mCall.getCallStateInt() == SipCall.CALL_STATE_CURRENT)) {
+
                     mCall.notifyServiceHangup(service);
                     finish();
                 }
diff --git a/src/com/savoirfairelinux/sflphone/client/SFLPhoneHome.java b/src/com/savoirfairelinux/sflphone/client/SFLPhoneHome.java
index e34696e693f81d3f2a6e4776028a25e330f0d7b9..c8bccc4a3808aaac794c97a4f750738d019cdf02 100644
--- a/src/com/savoirfairelinux/sflphone/client/SFLPhoneHome.java
+++ b/src/com/savoirfairelinux/sflphone/client/SFLPhoneHome.java
@@ -85,7 +85,6 @@ public class SFLPhoneHome extends Activity implements ActionBar.TabListener, OnC
     private String incomingCallID = "";
     private static final int REQUEST_CODE_PREFERENCES = 1;
     ImageButton buttonCall, buttonHangup;
-    Button buttonService;
     static Animation animation;
     ContactListFragment mContactListFragment;
     CallElementList mCallElementList;
@@ -95,6 +94,10 @@ public class SFLPhoneHome extends Activity implements ActionBar.TabListener, OnC
     public AccountList mAccountList = new AccountList();
     public CallList mCallList = new CallList(this);
 
+    private static final int ACTION_BAR_TAB_CONTACT = 0;
+    private static final int ACTION_BAR_TAB_CALL = 1;
+    private static final int ACTION_BAR_TAB_HISTORY = 2;
+
     /**
      * The {@link ViewPager} that will host the section contents.
      */
@@ -154,7 +157,7 @@ public class SFLPhoneHome extends Activity implements ActionBar.TabListener, OnC
             actionBar.addTab(actionBar.newTab().setIcon(icon_res_id[i]).setText(mSectionsPagerAdapter.getPageTitle(i)).setTabListener(this));
         }
 
-        actionBar.setSelectedNavigationItem(1);
+        actionBar.setSelectedNavigationItem(ACTION_BAR_TAB_CALL);
 
         buttonCall = (ImageButton) findViewById(R.id.buttonCall);
         buttonHangup = (ImageButton) findViewById(R.id.buttonHangUp);