Don't bug out if the LIST command doesn't have any parameters.
[gnus] / lisp / nnimap.el
index bdceb0d..c744796 100644 (file)
@@ -454,7 +454,8 @@ not done by default on servers that doesn't support that command.")
     (when (car result)
       (dolist (line (cdr result))
        (when (and (equal (car line) "LIST")
-                  (not (string-match "noselect" (caadr line))))
+                  (not (and (caadr line)
+                            (string-match "noselect" (caadr line)))))
          (push (car (last line)) groups)))
       (nreverse groups))))