aboutsummaryrefslogtreecommitdiffstats
path: root/embed/mozilla/GtkNSSDialogs.cpp
diff options
context:
space:
mode:
authorChristian Persch <chpe@cvs.gnome.org>2004-06-18 01:57:12 +0800
committerChristian Persch <chpe@src.gnome.org>2004-06-18 01:57:12 +0800
commitd5ea4ef0e4f4872a03e3ae9f41f23940f99922cc (patch)
tree8ac2c2d4b89c2ca98b2f3f15464c48743f26515e /embed/mozilla/GtkNSSDialogs.cpp
parentf2e8ab7c911d504732a40d74cbbb1aff2fec7e33 (diff)
downloadgsoc2013-epiphany-d5ea4ef0e4f4872a03e3ae9f41f23940f99922cc.tar
gsoc2013-epiphany-d5ea4ef0e4f4872a03e3ae9f41f23940f99922cc.tar.gz
gsoc2013-epiphany-d5ea4ef0e4f4872a03e3ae9f41f23940f99922cc.tar.bz2
gsoc2013-epiphany-d5ea4ef0e4f4872a03e3ae9f41f23940f99922cc.tar.lz
gsoc2013-epiphany-d5ea4ef0e4f4872a03e3ae9f41f23940f99922cc.tar.xz
gsoc2013-epiphany-d5ea4ef0e4f4872a03e3ae9f41f23940f99922cc.tar.zst
gsoc2013-epiphany-d5ea4ef0e4f4872a03e3ae9f41f23940f99922cc.zip
Escape strings before using the with markup in labels. Patch by Crispin
2004-06-17 Christian Persch <chpe@cvs.gnome.org> * embed/mozilla/GtkNSSClientAuthDialogs.cpp: * embed/mozilla/GtkNSSDialogs.cpp: Escape strings before using the with markup in labels. Patch by Crispin Flowerday.
Diffstat (limited to 'embed/mozilla/GtkNSSDialogs.cpp')
-rw-r--r--embed/mozilla/GtkNSSDialogs.cpp18
1 files changed, 9 insertions, 9 deletions
diff --git a/embed/mozilla/GtkNSSDialogs.cpp b/embed/mozilla/GtkNSSDialogs.cpp
index 1bd1a88e6..ff50a641b 100644
--- a/embed/mozilla/GtkNSSDialogs.cpp
+++ b/embed/mozilla/GtkNSSDialogs.cpp
@@ -291,10 +291,10 @@ GtkNSSDialogs::ConfirmMismatchDomain (nsIInterfaceRequestor *ctx,
NS_UTF16ToCString (commonName,
NS_CSTRING_ENCODING_UTF8, cCommonName);
- ttTargetUrl = g_strdup_printf ("\"<tt>%s</tt>\"",
- nsEmbedCString(targetURL).get());
+ ttTargetUrl = g_markup_printf_escaped ("\"<tt>%s</tt>\"",
+ nsEmbedCString(targetURL).get());
- ttCommonName = g_strdup_printf ("\"<tt>%s</tt>\"", cCommonName.get());
+ ttCommonName = g_markup_printf_escaped ("\"<tt>%s</tt>\"", cCommonName.get());
first = g_strdup_printf (_("The site %s returned security information for "
"%s. It is possible that someone is intercepting "
@@ -339,7 +339,7 @@ GtkNSSDialogs::ConfirmUnknownIssuer (nsIInterfaceRequestor *ctx,
NS_UTF16ToCString (commonName,
NS_CSTRING_ENCODING_UTF8, cCommonName);
- ttCommonName = g_strdup_printf ("\"<tt>%s</tt>\"", cCommonName.get());
+ ttCommonName = g_markup_printf_escaped ("\"<tt>%s</tt>\"", cCommonName.get());
secondary = g_strdup_printf
(_("Your browser was unable to trust %s. "
@@ -446,7 +446,7 @@ GtkNSSDialogs::ConfirmCertExpired (nsIInterfaceRequestor *ctx,
localtime_r (&t, &tm));
fdate = g_locale_to_utf8 (formattedDate, -1, NULL, NULL, NULL);
- ttCommonName = g_strdup_printf ("\"<tt>%s</tt>\"", cCommonName.get());
+ ttCommonName = g_markup_printf_escaped ("\"<tt>%s</tt>\"", cCommonName.get());
secondary = g_strdup_printf (text, ttCommonName, fdate);
@@ -495,10 +495,10 @@ GtkNSSDialogs::NotifyCrlNextupdate (nsIInterfaceRequestor *ctx,
NS_UTF16ToCString (commonName,
NS_CSTRING_ENCODING_UTF8, cCommonName);
- ttCommonName = g_strdup_printf ("\"<tt>%s</tt>\"", cCommonName.get());
+ ttCommonName = g_markup_printf_escaped ("\"<tt>%s</tt>\"", cCommonName.get());
- ttTargetUrl = g_strdup_printf ("\"<tt>%s</tt>\"",
- nsEmbedCString(targetURL).get());
+ ttTargetUrl = g_markup_printf_escaped ("\"<tt>%s</tt>\"",
+ nsEmbedCString(targetURL).get());
primary = g_strdup_printf (_("Cannot establish connection to %s."),
ttTargetUrl);
@@ -561,7 +561,7 @@ GtkNSSDialogs::ConfirmDownloadCACert(nsIInterfaceRequestor *ctx,
NS_UTF16ToCString (commonName,
NS_CSTRING_ENCODING_UTF8, cCommonName);
- ttCommonName = g_strdup_printf ("\"<tt>%s</tt>\"", cCommonName.get());
+ ttCommonName = g_markup_printf_escaped ("\"<tt>%s</tt>\"", cCommonName.get());
tertiary = g_strdup_printf (_("Trust %s to identify:"), ttCommonName);
g_free (ttCommonName);