emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: master eaf224f: Repad the Face header in Gnus


From: Alex Bochannek
Subject: Re: master eaf224f: Repad the Face header in Gnus
Date: Wed, 30 Sep 2020 11:40:08 -0700
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/27.1 (darwin)

Lars Ingebrigtsen <larsi@gnus.org> writes:

> Alex Bochannek <alex@bochannek.com> writes:
>
>> I also updated the tests accordingly. Please note that this
>> implementation /will/ fail a whitespace if it isn't followed by an
>> end-of-line. While updating that test, I cleaned up the other ones a
>> bit.
>
> But the use case here is an end-of-line followed by whitespace...

I meant a trailing whitespace by itself will fail because it isn't
unfolded and then constitutes a invalid base 64 character.

  (should (equal "Zm9vYmFy" (gnus-base64-repad "Zm9v\r\n YmFy\r\n")))
  (should (equal "Zm9vYmFy" (gnus-base64-repad "Zm9v \r\n\tYmFy")))

should cover the header field folding cases and

  (should-error (gnus-base64-repad "Zg== ")
                :type 'error)

covers a case for an invalid character in the base 64-string.

-- 
Alex.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]