aboutsummaryrefslogtreecommitdiffstats
path: root/Bugzilla
diff options
context:
space:
mode:
authorlpsolit%gmail.com <>2009-10-26 11:28:48 +0000
committerlpsolit%gmail.com <>2009-10-26 11:28:48 +0000
commitbd06859267aae5ec7bdcd1ae65fe145ef63adc54 (patch)
tree44778a8de27641d6aa6ffea90dee576b2aba44cc /Bugzilla
parent155bc6f800ebb5da30ff892105411da1163ae703 (diff)
downloadbugs-bd06859267aae5ec7bdcd1ae65fe145ef63adc54.tar
bugs-bd06859267aae5ec7bdcd1ae65fe145ef63adc54.tar.gz
bugs-bd06859267aae5ec7bdcd1ae65fe145ef63adc54.tar.bz2
bugs-bd06859267aae5ec7bdcd1ae65fe145ef63adc54.tar.xz
bugs-bd06859267aae5ec7bdcd1ae65fe145ef63adc54.zip
Bug 493242: UTF-8 characters in custom field names are mangled in show_activity.cgi - Patch by Vitaly Fedrushkov <vitaly.fedrushkov@gmail.com> r/a=LpSolit
Diffstat (limited to 'Bugzilla')
-rw-r--r--Bugzilla/Bug.pm15
-rw-r--r--Bugzilla/WebService/Bug.pm3
2 files changed, 2 insertions, 16 deletions
diff --git a/Bugzilla/Bug.pm b/Bugzilla/Bug.pm
index 528c6544c..456f77c9f 100644
--- a/Bugzilla/Bug.pm
+++ b/Bugzilla/Bug.pm
@@ -3133,14 +3133,7 @@ sub GetBugActivity {
$suppwhere = "AND COALESCE(attachments.isprivate, 0) = 0";
}
- my $query = "
- SELECT COALESCE(fielddefs.description, "
- # This is a hack - PostgreSQL requires both COALESCE
- # arguments to be of the same type, and this is the only
- # way supported by both MySQL 3 and PostgreSQL to convert
- # an integer to a string. MySQL 4 supports CAST.
- . $dbh->sql_string_concat('bugs_activity.fieldid', q{''}) .
- "), fielddefs.name, bugs_activity.attach_id, " .
+ my $query = "SELECT fielddefs.name, bugs_activity.attach_id, " .
$dbh->sql_date_format('bugs_activity.bug_when', '%Y.%m.%d %H:%i:%s') .
", bugs_activity.removed, bugs_activity.added, profiles.login_name
FROM bugs_activity
@@ -3163,7 +3156,7 @@ sub GetBugActivity {
my $incomplete_data = 0;
foreach my $entry (@$list) {
- my ($field, $fieldname, $attachid, $when, $removed, $added, $who) = @$entry;
+ my ($fieldname, $attachid, $when, $removed, $added, $who) = @$entry;
my %change;
my $activity_visible = 1;
@@ -3180,9 +3173,6 @@ sub GetBugActivity {
}
if ($activity_visible) {
- # This gets replaced with a hyperlink in the template.
- $field =~ s/^Attachment\s*// if $attachid;
-
# Check for the results of an old Bugzilla data corruption bug
$incomplete_data = 1 if ($added =~ /^\?/ || $removed =~ /^\?/);
@@ -3205,7 +3195,6 @@ sub GetBugActivity {
$operation->{'who'} = $who;
$operation->{'when'} = $when;
- $change{'field'} = $field;
$change{'fieldname'} = $fieldname;
$change{'attachid'} = $attachid;
$change{'removed'} = $removed;
diff --git a/Bugzilla/WebService/Bug.pm b/Bugzilla/WebService/Bug.pm
index 44382e79f..6a3e93519 100644
--- a/Bugzilla/WebService/Bug.pm
+++ b/Bugzilla/WebService/Bug.pm
@@ -220,9 +220,6 @@ sub history {
$change->{added} = $self->type('string', $change->{added});
$change->{field_name} = $self->type('string',
delete $change->{fieldname});
- # This is going to go away in the future from GetBugActivity
- # so we shouldn't put it in the API.
- delete $change->{field};
push (@{$bug_history{changes}}, $change);
}