[gitg] Escape subject commit text
- From: Alberto Fanjul <albfan src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gitg] Escape subject commit text
- Date: Tue, 19 Nov 2019 23:01:25 +0000 (UTC)
commit 5aed45af743b425b990b34e2069f2f865dcc99a5
Author: Rostyslav Arkadiev <rostyslav arkadiev gmail com>
Date: Mon Nov 18 01:54:48 2019 +0200
Escape subject commit text
Fixes #256
libgitg/gitg-diff-view-commit-details.vala | 7 ++++++-
1 file changed, 6 insertions(+), 1 deletion(-)
---
diff --git a/libgitg/gitg-diff-view-commit-details.vala b/libgitg/gitg-diff-view-commit-details.vala
index df2cc865..574b6c14 100644
--- a/libgitg/gitg-diff-view-commit-details.vala
+++ b/libgitg/gitg-diff-view-commit-details.vala
@@ -185,7 +185,7 @@ class Gitg.DiffViewCommitDetails : Gtk.Grid
return;
}
- d_label_subject.label = parse_links_on_subject(commit.get_subject());
+ d_label_subject.label = subject_to_markup(commit.get_subject());
d_label_sha1.label = commit.get_id().to_string();
var author = commit.get_author();
@@ -256,6 +256,11 @@ class Gitg.DiffViewCommitDetails : Gtk.Grid
update_avatar();
}
+ private string subject_to_markup(string subject_text)
+ {
+ return Markup.escape_text(parse_links_on_subject(subject_text));
+ }
+
private string parse_links_on_subject(string subject_text)
{
string result = subject_text.dup();
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]