diff options
-rw-r--r-- | ChangeLog | 6 | ||||
-rw-r--r-- | embed/mozilla/EventContext.cpp | 7 |
2 files changed, 11 insertions, 2 deletions
@@ -1,5 +1,11 @@ 2005-02-02 Christian Persch <chpe@cvs.gnome.org> + * embed/mozilla/EventContext.cpp: + + Don't copy params with the email address. Fixes bug #144469. + +2005-02-02 Christian Persch <chpe@cvs.gnome.org> + * src/ephy-automation.c: (impl_ephy_automation_loadUrlWithStartupId): * src/ephy-shell.c: (ephy_shell_new_window_cb), diff --git a/embed/mozilla/EventContext.cpp b/embed/mozilla/EventContext.cpp index 2001cfc0f..1472ee4d7 100644 --- a/embed/mozilla/EventContext.cpp +++ b/embed/mozilla/EventContext.cpp @@ -403,15 +403,18 @@ nsresult EventContext::GetEventContext (nsIDOMEventTarget *EventTarget, { /* cut "mailto:" */ href.Cut (0, 7); - // FIXME: cut any chars after "?" + + char *str = g_strdup (href.get()); + g_strdelimit (str, "?", '\0'); nsEmbedCString unescapedHref; - rv = Unescape (href, unescapedHref); + rv = Unescape (nsEmbedCString(str), unescapedHref); if (NS_SUCCEEDED (rv) && unescapedHref.Length()) { SetStringProperty ("email", unescapedHref.get()); info->context |= EPHY_EMBED_CONTEXT_EMAIL_LINK; } + g_free (str); } if (anchor && tmp.Length()) |