(wid-edit): Require.
[gnus] / lisp / smime.el
index fe8bb31..cb53418 100644 (file)
@@ -1,7 +1,7 @@
 ;;; smime.el --- S/MIME support library
 
 ;; Copyright (C) 2000, 2001, 2002, 2003, 2004,
-;;   2005 Free Software Foundation, Inc.
+;;   2005, 2006 Free Software Foundation, Inc.
 
 ;; Author: Simon Josefsson <simon@josefsson.org>
 ;; Keywords: SMIME X.509 PEM OpenSSL
@@ -594,7 +594,8 @@ A string or a list of strings is returned."
                                       host '("userCertificate") nil))
        (retbuf (generate-new-buffer (format "*certificate for %s*" mail)))
        cert)
-    (if (>= (length ldapresult) 1)
+    (if (and (>= (length ldapresult) 1)
+             (> (length (cadaar ldapresult)) 0))
        (with-current-buffer retbuf
          ;; Certificates on LDAP servers _should_ be in DER format,
          ;; but there are some servers out there that distributes the