GNU bug report logs -
#56867
[PATCH] download: Do not wrap TLS port on GnuTLS >= 3.7.7.
Previous Next
Reported by: Ludovic Courtès <ludo <at> gnu.org>
Date: Mon, 1 Aug 2022 09:09:02 UTC
Severity: normal
Tags: patch
Done: Ludovic Courtès <ludo <at> gnu.org>
Bug is archived. No further changes may be made.
Full log
Message #14 received at 56867 <at> debbugs.gnu.org (full text, mbox):
Hi,
Maxime Devos <maximedevos <at> telenet.be> skribis:
> On 01-08-2022 11:07, Ludovic Courtès wrote:
[...]
>> + (define (read! bv start count)
>> + (define read
>> + (catch 'gnutls-error
>> + (lambda ()
>> + (get-bytevector-n! record bv start count))
>> + (lambda (key err proc . rest)
>> + ;; When responding to "Connection: close" requests, some servers
>> + ;; close the connection abruptly after sending the response body,
>> + ;; without doing a proper TLS connection termination. Treat it as
>> + ;; EOF. This is fixed in GnuTLS 3.7.7.
>> + (if (eq? err error/premature-termination)
>> + the-eof-object
>> + (apply throw key err proc rest)))))
>
> Objection: 'catch' makes the backtrace part happening inside the
> 'get-bytevector-n!' disappear, because it is unwinding, as has been
> noted a few times (in different contexts) by Attila Lendvai and me.
> Maybe use 'guard' with an appropriate condition instead?
This code was already there and has just been moved around. (It’s also
code that will no longer be used going forward.)
>> + (if (module-defined? (resolve-interface '(gnutls))
>> + 'set-session-record-port-close!) ;GnuTLS >= 3.7.7
>
> resolve-module (and presumably also sets #:ensure #t by default, which
> sometimes causes 'module not found' messages to be replaced by
> 'unbound variable', which I don't think is useful behaviour, can
> #:ensure be set to #false?
This is unnecessary: see the ‘load-gnutls’ mechanism there. The idiom
above is already used in a couple of places.
Thanks for your feedback!
Ludo’.
This bug report was last modified 2 years and 292 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.