projects
/
radsecproxy.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Improve protocol robustness and invoke user callbacks.
[radsecproxy.git]
/
lib
/
debug.c
diff --git
a/lib/debug.c
b/lib/debug.c
index
485e29a
..
4544f3c
100644
(file)
--- a/
lib/debug.c
+++ b/
lib/debug.c
@@
-14,8
+14,11
@@
void
rs_dump_packet (const struct rs_packet *pkt)
{
void
rs_dump_packet (const struct rs_packet *pkt)
{
- const RADIUS_PACKET *p = pkt->rpkt;
- assert(p);
+ const RADIUS_PACKET *p = NULL;
+
+ if (!pkt || !pkt->rpkt)
+ return;
+ p = pkt->rpkt;
fprintf (stderr, "\tCode: %u, Identifier: %u, Lenght: %u\n",
p->code,
fprintf (stderr, "\tCode: %u, Identifier: %u, Lenght: %u\n",
p->code,
@@
-32,7
+35,7
@@
rs_dump_attr (const struct rs_attr *attr)
#if defined DEBUG
int
#if defined DEBUG
int
-rs_debug (const char *fmt, ...)
+
_
rs_debug (const char *fmt, ...)
{
int n;
va_list args;
{
int n;
va_list args;