Code Review
/
src
/
app-framework-binder.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
review
|
tree
raw
|
inline
| side by side
fix SEGFLT when unhendled request
[src/app-framework-binder.git]
/
src
/
afb-hsrv.c
diff --git
a/src/afb-hsrv.c
b/src/afb-hsrv.c
index
91dff29
..
577ef85
100644
(file)
--- a/
src/afb-hsrv.c
+++ b/
src/afb-hsrv.c
@@
-238,9
+238,11
@@
static void end_handler(void *cls, struct MHD_Connection *connection, void **rec
struct afb_hreq *hreq;
hreq = *recordreq;
struct afb_hreq *hreq;
hreq = *recordreq;
- if (hreq->upgrade)
- MHD_suspend_connection (connection);
- afb_hreq_unref(hreq);
+ if (hreq) {
+ if (hreq->upgrade)
+ MHD_suspend_connection (connection);
+ afb_hreq_unref(hreq);
+ }
}
void run_micro_httpd(struct afb_hsrv *hsrv)
}
void run_micro_httpd(struct afb_hsrv *hsrv)