diff options
| author | Lars Magne Ingebrigtsen | 2011-07-27 22:45:56 +0200 |
|---|---|---|
| committer | Lars Magne Ingebrigtsen | 2011-07-27 22:45:56 +0200 |
| commit | dbf38e02c9ade4979418f24a99962cfef170b957 (patch) | |
| tree | 7415b0a94ed1a3998d900559f4a1f82caf4b750f | |
| parent | 427c285b5782e1c1c581be01e085a77343bb2c79 (diff) | |
| download | emacs-dbf38e02c9ade4979418f24a99962cfef170b957.tar.gz emacs-dbf38e02c9ade4979418f24a99962cfef170b957.zip | |
Silence error message we get in gnutls when the peer hangs up
* gnutls.c (emacs_gnutls_read): Don't message anything if the peer
closes the connection while we're reading.
Fixes: debbugs:9182
| -rw-r--r-- | src/ChangeLog | 5 | ||||
| -rw-r--r-- | src/gnutls.c | 3 |
2 files changed, 8 insertions, 0 deletions
diff --git a/src/ChangeLog b/src/ChangeLog index dd25d155c66..e204ff2040b 100644 --- a/src/ChangeLog +++ b/src/ChangeLog | |||
| @@ -1,3 +1,8 @@ | |||
| 1 | 2011-07-27 Lars Magne Ingebrigtsen <larsi@gnus.org> | ||
| 2 | |||
| 3 | * gnutls.c (emacs_gnutls_read): Don't message anything if the peer | ||
| 4 | closes the connection while we're reading (bug#9182). | ||
| 5 | |||
| 1 | 2011-07-25 Jan Djärv <jan.h.d@swipnet.se> | 6 | 2011-07-25 Jan Djärv <jan.h.d@swipnet.se> |
| 2 | 7 | ||
| 3 | * nsmenu.m (ns_popup_dialog): Add an "ok" button if no buttons | 8 | * nsmenu.m (ns_popup_dialog): Add an "ok" button if no buttons |
diff --git a/src/gnutls.c b/src/gnutls.c index 3175f55041d..fc651d2c7e4 100644 --- a/src/gnutls.c +++ b/src/gnutls.c | |||
| @@ -382,6 +382,9 @@ emacs_gnutls_read (struct Lisp_Process *proc, char *buf, EMACS_INT nbyte) | |||
| 382 | rtnval = fn_gnutls_record_recv (state, buf, nbyte); | 382 | rtnval = fn_gnutls_record_recv (state, buf, nbyte); |
| 383 | if (rtnval >= 0) | 383 | if (rtnval >= 0) |
| 384 | return rtnval; | 384 | return rtnval; |
| 385 | else if (rtnval == GNUTLS_E_UNEXPECTED_PACKET_LENGTH) | ||
| 386 | /* The peer closed the connection. */ | ||
| 387 | return 0; | ||
| 385 | else if (emacs_gnutls_handle_error (state, rtnval) == 0) | 388 | else if (emacs_gnutls_handle_error (state, rtnval) == 0) |
| 386 | /* non-fatal error */ | 389 | /* non-fatal error */ |
| 387 | return -1; | 390 | return -1; |