diff options
author | Michael Drake <tlsa@netsurf-browser.org> | 2012-10-05 16:58:59 +0100 |
---|---|---|
committer | Michael Drake <tlsa@netsurf-browser.org> | 2012-10-05 16:58:59 +0100 |
commit | 16bcecc378b285dada1458173def346c3ac0be9e (patch) | |
tree | b43508a07dd9069f320c1a332855e18de698b5c6 /render | |
parent | 3c4f4ca461e1c73e8e6ab815ff8fc5e5201a78f5 (diff) | |
download | netsurf-16bcecc378b285dada1458173def346c3ac0be9e.tar.gz netsurf-16bcecc378b285dada1458173def346c3ac0be9e.tar.bz2 |
Talloc ctx fixup.
Diffstat (limited to 'render')
-rw-r--r-- | render/textinput.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/render/textinput.c b/render/textinput.c index 98746bca1..15e89f20d 100644 --- a/render/textinput.c +++ b/render/textinput.c @@ -296,7 +296,7 @@ static bool textinput_textbox_insert(struct content *c, } /* insert in text box */ - text = talloc_realloc(c, text_box->text, + text = talloc_realloc(html->bctx, text_box->text, char, text_box->length + SPACE_LEN(text_box) + utf8_len + 1); if (!text) { @@ -626,18 +626,19 @@ static bool textinput_textarea_cut(struct content *c, static struct box *textinput_textarea_insert_break(struct content *c, struct box *text_box, size_t char_offset) { + html_content *html = (html_content *)c; struct box *new_br, *new_text; char *text; - text = talloc_array(c, char, text_box->length + 1); + text = talloc_array(html->bctx, char, text_box->length + 1); if (!text) { warn_user("NoMemory", 0); return NULL; } new_br = box_create(NULL, text_box->style, false, 0, 0, text_box->title, - 0, c); - new_text = talloc(c, struct box); + 0, html->bctx); + new_text = talloc(html->bctx, struct box); if (!new_text) { warn_user("NoMemory", 0); return NULL; |