diff --git a/alot/command.py b/alot/command.py
index <HASH>..<HASH> 100644
--- a/alot/command.py
+++ b/alot/command.py
@@ -101,7 +101,7 @@ class SearchCommand(Command):
 
     def apply(self, ui):
         if self.query:
-            if self.query == '*':
+            if self.query == '*' and ui.current_buffer:
                 s = 'really search for all threads? This takes a while..'
                 if not ui.choice(s) == 'yes':
                     return
fix: issue with initial searches for *

for the searchstring '*' an orly? prompt is
hardcoded as these tend to take long. Prompts
don't work if the ui is not properly set up.