mirror of
https://github.com/cesanta/mongoose.git
synced 2026-10-21 11:30:01 +00:00
1 parent
5574a2663a
commit
3c71977e2e
2 files changed
+8
-4
No files matched your search
+4
-2
@@ -3546,8 +3546,10 @@ void mg_mgr_init(struct mg_mgr *mgr) {
|
||||
void mg_rpc_add(struct mg_rpc **head, struct mg_str method,
|
||||
void (*fn)(struct mg_rpc_req *), void *fn_data) {
|
||||
struct mg_rpc *rpc = (struct mg_rpc *) calloc(1, sizeof(*rpc));
|
||||
rpc->method = mg_strdup(method), rpc->fn = fn, rpc->fn_data = fn_data;
|
||||
rpc->next = *head, *head = rpc;
|
||||
if (rpc != NULL) {
|
||||
rpc->method = mg_strdup(method), rpc->fn = fn, rpc->fn_data = fn_data;
|
||||
rpc->next = *head, *head = rpc;
|
||||
}
|
||||
}
|
||||
|
||||
void mg_rpc_del(struct mg_rpc **head, void (*fn)(struct mg_rpc_req *)) {
|
||||
|
||||
@@ -3,8 +3,10 @@
|
||||
void mg_rpc_add(struct mg_rpc **head, struct mg_str method,
|
||||
void (*fn)(struct mg_rpc_req *), void *fn_data) {
|
||||
struct mg_rpc *rpc = (struct mg_rpc *) calloc(1, sizeof(*rpc));
|
||||
rpc->method = mg_strdup(method), rpc->fn = fn, rpc->fn_data = fn_data;
|
||||
rpc->next = *head, *head = rpc;
|
||||
if (rpc != NULL) {
|
||||
rpc->method = mg_strdup(method), rpc->fn = fn, rpc->fn_data = fn_data;
|
||||
rpc->next = *head, *head = rpc;
|
||||
}
|
||||
}
|
||||
|
||||
void mg_rpc_del(struct mg_rpc **head, void (*fn)(struct mg_rpc_req *)) {
|
||||
|
||||
Reference in new issue
Block a user