Re: git svn log: Use of uninitialized value $sha1_short

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

 



On Wed, Oct 21, 2020 at 09:42:12PM +0300, Nikos Chantziaras wrote:

> Running 'git svn log' in a repository that was cloned from an SVN repo
> results in this warning:
> 
> $ git svn log > /dev/null
> Use of uninitialized value $sha1_short in regexp compilation at
> /usr/lib64/perl5/vendor_perl/5.30.3/Git/SVN/Log.pm line 301, <$fh> line 6.
> 
> This doesn't appear to have any ill effects, but the warning might indicate
> a problem somewhere.

It seems to only get mentioned once and never set:

  $ git grep sha1_short perl
  perl/Git/SVN/Log.pm:            } elsif (/^${esc_color}:\d{6} \d{6} $::sha1_short/o) {

Looks like it got renamed, and this reference was somehow missed?

  $ git log -1 -Ssha1_short perl
  commit 9ab33150a0d14089d0496dd8354d4a969e849571
  Author: brian m. carlson <sandals@xxxxxxxxxxxxxxxxxxxx>
  Date:   Mon Jun 22 18:04:12 2020 +0000
  
      perl: create and switch variables for hash constants
      
      git-svn has several variables for SHA-1 constants, including short hash
      values and full length hash values.  Since these are no longer SHA-1
      specific, let's start them with "oid" instead of "sha1".  Add a
      constant, oid_length, which is the length of the hash algorithm in use
      in hex.  We use the hex version because overwhelmingly that's what's
      used by git-svn.
  [...]

-Peff



[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]

  Powered by Linux