From: Ben Walton <bwalton@artsci.utoronto.ca>
To: normalperson@yhbt.net
Cc: git@vger.kernel.org, Ben Walton <bwalton@artsci.utoronto.ca>
Subject: [PATCH] git-svn - return original format_svn_date semantics
Date: Fri, 27 Feb 2009 22:11:45 -0500 [thread overview]
Message-ID: <1235790705-12903-1-git-send-email-bwalton@artsci.utoronto.ca> (raw)
When %z was removed from the strftime call and subsituted with a
local gmt offset calculation, time() was no longer the default for
all time functions as it was with the previous localtime(shift).
This is now corrected so that format_svn_time behaves as it used to.
Signed-off-by: Ben Walton <bwalton@artsci.utoronto.ca>
---
git-svn.perl | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/git-svn.perl b/git-svn.perl
index d967594..55702d0 100755
--- a/git-svn.perl
+++ b/git-svn.perl
@@ -4738,7 +4738,7 @@ sub run_pager {
sub format_svn_date {
# some systmes don't handle or mishandle %z, so be creative.
- my $t = shift;
+ my $t = shift || time;
my $gm = timelocal(gmtime($t));
my $sign = qw( + + - )[ $t <=> $gm ];
my $gmoff = sprintf("%s%02d%02d", $sign, (gmtime(abs($t - $gm)))[2,1]);
--
1.6.0.4
next reply other threads:[~2009-02-28 3:13 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-02-28 3:11 Ben Walton [this message]
2009-02-28 3:22 ` [PATCH] git-svn - return original format_svn_date semantics Eric Wong
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1235790705-12903-1-git-send-email-bwalton@artsci.utoronto.ca \
--to=bwalton@artsci.utoronto.ca \
--cc=git@vger.kernel.org \
--cc=normalperson@yhbt.net \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox