Commit b50c183c authored by Marko Mikulicic's avatar Marko Mikulicic Committed by Sergey Lyubka

Simplify and abstract C func arg access

    PUBLISHED_FROM=c174439a2d22794497dc35fd46ceb1f6c4e553a2
parent a941687d
......@@ -1890,9 +1890,9 @@ void mg_mgr_init(struct mg_mgr *m, void *user_data) {
}
#ifdef MG_ENABLE_JAVASCRIPT
static v7_val_t mg_send_js(struct v7 *v7, v7_val_t args) {
v7_val_t arg0 = v7_array_get(v7, args, 0);
v7_val_t arg1 = v7_array_get(v7, args, 1);
static v7_val_t mg_send_js(struct v7 *v7) {
v7_val_t arg0 = v7_arg(v7, 0);
v7_val_t arg1 = v7_arg(v7, 1);
struct mg_connection *c = (struct mg_connection *) v7_to_foreign(arg0);
size_t len = 0;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment