diff --git a/dlls/mshtml/htmlform.c b/dlls/mshtml/htmlform.c
index 0f77d28cb14..e53dbc07707 100644
--- a/dlls/mshtml/htmlform.c
+++ b/dlls/mshtml/htmlform.c
@@ -174,6 +174,7 @@ static HRESULT WINAPI HTMLFormElement_get_action(IHTMLFormElement *iface, BSTR *
hres = E_FAIL;
}
+ nsAString_Finish(&action_str);
return hres;
}