diff --git a/src/html/htmltag.cpp b/src/html/htmltag.cpp
index 6def30c189..c24739b189 100644
--- a/src/html/htmltag.cpp
+++ b/src/html/htmltag.cpp
@@ -149,8 +149,6 @@ wxHtmlTagsCache::wxHtmlTagsCache(const wxString& source)
// found a match
if (match_pos == tag_len) {
pos = pos - tag_len - 3;
- stpos = pos;
- wxUnusedVar(stpos);
break;
}
else {