diff --git a/src/html.cc b/src/html.cc
index a57a1c6..acfc436 100644
--- a/src/html.cc
+++ b/src/html.cc
@@ -23,6 +23,8 @@
#include /* for sprintf */
#include
+#include
+
#include "bw.h" /* for BrowserWindow */
#include "msg.h"
#include "binaryconst.h"
@@ -1942,7 +1944,6 @@ static void
Html_tag_content_frame (DilloHtml *html, const char *tag, int tagsize)
{
const char *attrbuf;
- char *src;
Textblock *textblock;
Widget *bullet;
@@ -1951,7 +1952,7 @@ static void
if (!(attrbuf = a_Html_get_attr(html, tag, tagsize, "src")))
return;
- src = dStrdup(attrbuf);
+ std::string src = attrbuf;
textblock->addParbreak (5, html->wordStyle ());
@@ -1968,15 +1969,13 @@ static void
/* FRAME:
* If 'name' tag is present use it, if not use 'src' value */
if (!(attrbuf = a_Html_get_attr(html, tag, tagsize, "name"))) {
- textblock->addText (src, html->wordStyle ());
+ textblock->addText (src.c_str(), html->wordStyle ());
} else {
textblock->addText (attrbuf, html->wordStyle ());
}
}
textblock->addParbreak (5, html->wordStyle ());
-
- dFree(src);
}
/*