static struct ns_connection *get_nc(struct v7_val *obj) { struct v7_val key = v7_str_to_val("nc"), *p = v7_get(obj, &key); struct ns_connection *nc = NULL; if (p != NULL) { unsigned long num = (unsigned long) p->v.num; nc = (struct ns_connection *) num; } return nc; }
struct v7_val *v7_lookup(struct v7_val *obj, const char *key) { struct v7_val k = v7_str_to_val(key); return get2(obj, &k); }