diff options
| author | Sadeep Madurange <sadeep@asciimx.com> | 2026-05-06 17:46:49 +0800 |
|---|---|---|
| committer | Sadeep Madurange <sadeep@asciimx.com> | 2026-05-06 17:46:49 +0800 |
| commit | 8f0c3d4697742fb64cb1af8ba28fa2bb6f99de5a (patch) | |
| tree | 1822d135ec879620361e1d80cb54a63d2d8d3602 /wv_dom.c | |
| parent | fd2d93f4a97ab5a3bc18764c353b971b4035ac6a (diff) | |
| download | web-view-master.tar.gz | |
Diffstat (limited to 'wv_dom.c')
| -rw-r--r-- | wv_dom.c | 7 |
1 files changed, 4 insertions, 3 deletions
@@ -8,7 +8,7 @@ wv_ref wv_node_new(struct wv_arena *arena, wv_node_type type) wv_ref ref; struct wv_node *node; - ref = wv_alloc(arena, sizeof(struct wv_node)); + ref = wv_arena_alloc(arena, sizeof(struct wv_node)); node = (struct wv_node *)WV_ADDR(arena, ref); memset(node, 0, sizeof(struct wv_node)); node->type = type; @@ -50,9 +50,10 @@ void wv_attr_set(struct wv_arena *arena, wv_ref node_ref, struct wv_attr *a; n = (struct wv_node *)WV_ADDR(arena, node_ref); - if (n->type != WV_NODE_ELEMENT) return; + if (n->type != WV_NODE_ELEMENT) + return; - attr_ref = wv_alloc(arena, sizeof(struct wv_attr)); + attr_ref = wv_arena_alloc(arena, sizeof(struct wv_attr)); a = (struct wv_attr *)WV_ADDR(arena, attr_ref); a->key = key_str; |
