projects
/
libradsec.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
5ca193d
)
Missing response packet in rs_conn_receive_packet doesn't have to be a bug.
author
Linus Nordberg
<linus@nordu.net>
Wed, 25 Apr 2012 13:23:06 +0000
(15:23 +0200)
committer
Linus Nordberg
<linus@nordu.net>
Wed, 25 Apr 2012 13:23:06 +0000
(15:23 +0200)
lib/conn.c
patch
|
blob
|
history
diff --git
a/lib/conn.c
b/lib/conn.c
index
ee5e771
..
33642e3
100644
(file)
--- a/
lib/conn.c
+++ b/
lib/conn.c
@@
-269,7
+269,10
@@
rs_conn_receive_packet (struct rs_connection *conn,
|| (req_msg
&& packet_verify_response (pkt->conn, pkt, req_msg) != RSE_OK))
{
- assert (rs_err_conn_peek_code (pkt->conn));
+ if (rs_err_conn_peek_code (pkt->conn) == RSE_OK)
+ /* No packet and no error on the stack _should_ mean that the
+ server hung up on us. */
+ rs_err_conn_push (pkt->conn, RSE_DISCO, "no response");
return rs_err_conn_peek_code (conn);
}