GNU bug report logs - #64089
30.0.50; `ldap-search' errors out with `wrong-type-argument listp' when called WITHDN == t

Previous Next

Package: emacs;

Reported by: Jens Schmidt <jschmidt4gnu <at> vodafonemail.de>

Date: Thu, 15 Jun 2023 21:29:02 UTC

Severity: normal

Fixed in version 30.0.50

Done: Filipp Gunbin <fgunbin <at> fastmail.fm>

Bug is archived. No further changes may be made.

Full log


Message #47 received at 64089 <at> debbugs.gnu.org (full text, mbox):

From: Eli Zaretskii <eliz <at> gnu.org>
To: Jens Schmidt <jschmidt4gnu <at> vodafonemail.de>
Cc: 64089 <at> debbugs.gnu.org, fgunbin <at> fastmail.fm, monnier <at> iro.umontreal.ca
Subject: Re: bug#64089: 30.0.50; `ldap-search' errors out with
 `wrong-type-argument listp' when called WITHDN == t
Date: Sun, 18 Jun 2023 11:56:11 +0300
> Date: Sun, 18 Jun 2023 10:51:25 +0200
> From: Jens Schmidt <jschmidt4gnu <at> vodafonemail.de>
> Cc: 64089 <at> debbugs.gnu.org, monnier <at> iro.umontreal.ca
> 
> On 2023-06-18  09:43, Jens Schmidt wrote:
> 
> > Or whatever.  In any case, I'll open a new bug for that to continue 
> > this discussion.
> 
> And of course, Filipp is right w.r.t. to API consistency.  TBH, I simply
> haven't payed attention to `ldap-ignore-attribute-codings' until
> recently.  So for emacs-29, I can provide a patch that backs out my
> previous patch and fixes the bug such that the *original/Gerd's* string
> 
>    "dn: cn=JENS_SCHMIDT,L=REGION,DC=COMPANY,DC=COM"
> 
> gets appended to the result w/o triggering the
> 
>    wrong-type-argument listp
> 
> for both `ldap-ignore-attribute-codings' equaling nil and non-nil.
> 
> Basicaly the upper half of Filipp's patch, but redone such that even I
> understand it without too much eye-balling :-).  Like this probably (not
> tested yet!):
> 
>      (cond
>       (ldap-ignore-attribute-codings
>        result)
>       (withdn
>        ;; Do not process first elements of the records
>        ;; with `ldap-decode-attribute' (Bug#64089).
>        (mapcar (lambda (record)
>                  (cons (car record)
> 		      (mapcar #'ldap-decode-attribute
>                                (cdr record)))
> 	        result)))
>       (t
>        (mapcar (lambda (record)
> 		(mapcar #'ldap-decode-attribute record))
>                  result))))
> 
> WDYT?

I'm uncomfortable with non-trivial changes, so if this is anywhere
like Filipp's proposal, I'd rather leave it unfixed on emacs-29.




This bug report was last modified 2 years and 27 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.