fix tab NPE

    http://b/issue?id=3381168
    add check if tab is null when attaching a tab

Change-Id: I2e53b242be829c6ed2e6eb22539eb71bee0269bf
diff --git a/src/com/android/browser/BaseUi.java b/src/com/android/browser/BaseUi.java
index 5deb335..568a7e9 100644
--- a/src/com/android/browser/BaseUi.java
+++ b/src/com/android/browser/BaseUi.java
@@ -253,7 +253,7 @@
     }
 
     private void attachTabToContentView(Tab tab) {
-        if (tab.getWebView() == null) {
+        if ((tab == null) || (tab.getWebView() == null)) {
             return;
         }
         View container = tab.getViewContainer();