Re: [PATCH -1/3] gitweb: Always call parse_date with timezone parameter

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Sat, Mar 19, 2011 at 3:18 PM, Jakub Narebski <jnareb@xxxxxxxxx> wrote:
> @@ -4906,7 +4906,7 @@ sub git_log_body {
> Â Â Â Â Â Â Â Ânext if !%co;
> Â Â Â Â Â Â Â Âmy $commit = $co{'id'};
> Â Â Â Â Â Â Â Âmy $ref = format_ref_marker($refs, $commit);
> - Â Â Â Â Â Â Â my %ad = parse_date($co{'author_epoch'});
> + Â Â Â Â Â Â Â my %ad = parse_date($co{'author_epoch'}, $co{'athor_tz'});

Should be 'author_tz'

Looking at the master branch, I don't see %ad actually getting used
anywhere?  Maybe it is safe to delete the line entirely, since
git_print_authorship() calls parse_date() itself.

> @@ -7064,7 +7064,7 @@ sub git_feed {
> Â Â Â Âif (defined($commitlist[0])) {
> Â Â Â Â Â Â Â Â%latest_commit = %{$commitlist[0]};
> Â Â Â Â Â Â Â Âmy $latest_epoch = $latest_commit{'committer_epoch'};
> -        %latest_date  = parse_date($latest_epoch);
> +        %latest_date  = parse_date($latest_epoch, $latest_commit{'comitter_tz'});

Should be 'committer_tz'

I would agree that it isn't such a good thing for
$latest_date{'rfc2822_local'} to be set to GMT in this case.  Although
the feeds don't need local times for anything, since RSS/Atom readers
seem to do their own timezone translations.

It probably makes sense to add this argument so that nobody gets bit
later when they try to use the rfc2822_local field.

Am I correct in interpreting "PATCH -1/3" as: "apply this before
Kevin's set of 3 patches?"
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]