From 8a676ab2d88022aea68a2a31ac83dfe25d64e175 Mon Sep 17 00:00:00 2001 From: Linus Nordberg Date: Sun, 10 Oct 2010 15:53:37 +0200 Subject: Robustness fixes (and some callback invocation) by Luke Howard. * lib/packet.c (_packet_create): Set packet identity properly. (_do_send): Return an int. (_do_send): Don't ignore rad_encode() errors. (_do_send): Do invoke rad_sign(). (_event_cb): Invoke callbacks. (_event_cb): Honour _do_send() return code. (_read_cb): Check packet (by invoking rad_packet_ok()). (_read_cb): Don't ignore rad_decode() errors. (_read_cb): Invoke callbacks. --- lib/include/radsec/radsec-impl.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'lib/include/radsec') diff --git a/lib/include/radsec/radsec-impl.h b/lib/include/radsec/radsec-impl.h index b46bc47..d2ea095 100644 --- a/lib/include/radsec/radsec-impl.h +++ b/lib/include/radsec/radsec-impl.h @@ -63,9 +63,11 @@ struct rs_connection { enum rs_conn_type type; struct rs_credentials transport_credentials; struct rs_conn_callbacks callbacks; + void *user_data; struct rs_peer *peers; struct rs_peer *active_peer; struct rs_error *err; + int nextid; }; struct rs_packet { -- cgit v1.1