You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@subversion.apache.org by da...@apache.org on 2013/05/23 01:10:28 UTC
svn commit: r1485487 - in /subversion/branches: 1.6.x/
1.6.x/contrib/hook-scripts/ 1.7.x/ 1.7.x/contrib/hook-scripts/ 1.8.x/
1.8.x/contrib/hook-scripts/
Author: danielsh
Date: Wed May 22 23:10:27 2013
New Revision: 1485487
URL: http://svn.apache.org/r1485487
Log:
Merge r1485350 from trunk:
* r1485350
contrib: fix some argument passing.
Justification:
More robust that way.
Votes:
+1: danielsh, stsp, breser
Modified:
subversion/branches/1.6.x/ (props changed)
subversion/branches/1.6.x/STATUS
subversion/branches/1.6.x/contrib/hook-scripts/check-mime-type.pl
subversion/branches/1.6.x/contrib/hook-scripts/svn-keyword-check.pl
subversion/branches/1.7.x/ (props changed)
subversion/branches/1.7.x/STATUS
subversion/branches/1.7.x/contrib/hook-scripts/check-mime-type.pl
subversion/branches/1.7.x/contrib/hook-scripts/svn-keyword-check.pl
subversion/branches/1.8.x/ (props changed)
subversion/branches/1.8.x/STATUS
subversion/branches/1.8.x/contrib/hook-scripts/check-mime-type.pl
subversion/branches/1.8.x/contrib/hook-scripts/svn-keyword-check.pl
Propchange: subversion/branches/1.6.x/
------------------------------------------------------------------------------
Merged /subversion/trunk:r1485350
Modified: subversion/branches/1.6.x/STATUS
URL: http://svn.apache.org/viewvc/subversion/branches/1.6.x/STATUS?rev=1485487&r1=1485486&r2=1485487&view=diff
==============================================================================
--- subversion/branches/1.6.x/STATUS (original)
+++ subversion/branches/1.6.x/STATUS Wed May 22 23:10:27 2013
@@ -89,10 +89,3 @@ Veto-blocked changes:
Approved changes:
=================
-
- * r1485350
- contrib: fix some argument passing.
- Justification:
- More robust that way.
- Votes:
- +1: danielsh, stsp, breser
Modified: subversion/branches/1.6.x/contrib/hook-scripts/check-mime-type.pl
URL: http://svn.apache.org/viewvc/subversion/branches/1.6.x/contrib/hook-scripts/check-mime-type.pl?rev=1485487&r1=1485486&r2=1485487&view=diff
==============================================================================
--- subversion/branches/1.6.x/contrib/hook-scripts/check-mime-type.pl (original)
+++ subversion/branches/1.6.x/contrib/hook-scripts/check-mime-type.pl Wed May 22 23:10:27 2013
@@ -120,7 +120,7 @@ foreach my $path ( @files_added )
# Parse the complete list of property values of the file $path to extract
# the mime-type and eol-style
foreach my $prop (&read_from_process($svnlook, 'proplist', $repos, '-t',
- $txn, '--verbose', $path))
+ $txn, '--verbose', '--', $path))
{
if ($prop =~ /^\s*svn:mime-type : (\S+)/)
{
@@ -187,7 +187,7 @@ sub safe_read_from_pipe
croak "$0: safe_read_from_pipe passed no arguments.\n";
}
print "Running @_\n";
- my $pid = open(SAFE_READ, '-|');
+ my $pid = open(SAFE_READ, '-|', @_);
unless (defined $pid)
{
die "$0: cannot fork: $!\n";
Modified: subversion/branches/1.6.x/contrib/hook-scripts/svn-keyword-check.pl
URL: http://svn.apache.org/viewvc/subversion/branches/1.6.x/contrib/hook-scripts/svn-keyword-check.pl?rev=1485487&r1=1485486&r2=1485487&view=diff
==============================================================================
--- subversion/branches/1.6.x/contrib/hook-scripts/svn-keyword-check.pl (original)
+++ subversion/branches/1.6.x/contrib/hook-scripts/svn-keyword-check.pl Wed May 22 23:10:27 2013
@@ -141,7 +141,7 @@ sub check {
return 1;
} else {
my @keywords = get_svnkeywords($file);
- my $fh = _pipe("$svnlook cat $flag $value $repos $file");
+ my $fh = _pipe($svnlook, qw/cat/, $flag, $value, $repos, '--', $file);
while (my $line = <$fh>) {
foreach my $keyword (@keywords) {
if ($line =~ m/$keyword/) {
@@ -168,7 +168,7 @@ sub file_is_binary {
return 0;
}
if (has_svn_property($file, "svn:mime-type")) {
- my ($mimetype) = read_from_process("$svnlook propget $flag $value $repos svn:mime-type $file");
+ my ($mimetype) = read_from_process($svnlook, qw/propget/, $flag, $value, $repos, 'svn:mime-type', '--', $file);
chomp($mimetype);
$mimetype =~ s/^\s*(.*)/$1/;
if ($mimetype =~ m/^text\//) {
@@ -186,7 +186,7 @@ sub file_is_binary {
# Return a list of svn:keywords on a file
sub get_svnkeywords {
my $file = shift;
- my @lines = read_from_process("$svnlook propget $flag $value $repos svn:keywords $file");
+ my @lines = read_from_process($svnlook, qw/propget/, $flag, $value, $repos, 'svn:keywords', '--', $file);
my @returnlines;
foreach my $line (@lines) {
$line =~ s/\s+/ /;
@@ -199,7 +199,7 @@ sub get_svnkeywords {
sub has_svn_property {
my $file = shift;
my $keyword = shift;
- my @proplist = read_from_process("$svnlook proplist $flag $value $repos $file");
+ my @proplist = read_from_process($svnlook, qw/proplist/, $flag, $value, $repos, '--', $file);
foreach my $prop (@proplist) {
chomp($prop);
if ($prop =~ m/\b$keyword\b/) {
@@ -241,7 +241,7 @@ sub safe_read_from_pipe {
# Return the filehandle as a glob so we can loop over it elsewhere.
sub _pipe {
local *SAFE_READ;
- my $pid = open(SAFE_READ, '-|');
+ my $pid = open(SAFE_READ, '-|', @_);
unless (defined $pid) {
die "$0: cannot fork: $!\n";
}
Propchange: subversion/branches/1.7.x/
------------------------------------------------------------------------------
Merged /subversion/trunk:r1485350
Modified: subversion/branches/1.7.x/STATUS
URL: http://svn.apache.org/viewvc/subversion/branches/1.7.x/STATUS?rev=1485487&r1=1485486&r2=1485487&view=diff
==============================================================================
--- subversion/branches/1.7.x/STATUS (original)
+++ subversion/branches/1.7.x/STATUS Wed May 22 23:10:27 2013
@@ -181,10 +181,3 @@ Veto-blocked changes:
Approved changes:
=================
-
- * r1485350
- contrib: fix some argument passing.
- Justification:
- More robust that way.
- Votes:
- +1: danielsh, stsp, breser
Modified: subversion/branches/1.7.x/contrib/hook-scripts/check-mime-type.pl
URL: http://svn.apache.org/viewvc/subversion/branches/1.7.x/contrib/hook-scripts/check-mime-type.pl?rev=1485487&r1=1485486&r2=1485487&view=diff
==============================================================================
--- subversion/branches/1.7.x/contrib/hook-scripts/check-mime-type.pl (original)
+++ subversion/branches/1.7.x/contrib/hook-scripts/check-mime-type.pl Wed May 22 23:10:27 2013
@@ -120,7 +120,7 @@ foreach my $path ( @files_added )
# Parse the complete list of property values of the file $path to extract
# the mime-type and eol-style
foreach my $prop (&read_from_process($svnlook, 'proplist', $repos, '-t',
- $txn, '--verbose', $path))
+ $txn, '--verbose', '--', $path))
{
if ($prop =~ /^\s*svn:mime-type : (\S+)/)
{
@@ -187,7 +187,7 @@ sub safe_read_from_pipe
croak "$0: safe_read_from_pipe passed no arguments.\n";
}
print "Running @_\n";
- my $pid = open(SAFE_READ, '-|');
+ my $pid = open(SAFE_READ, '-|', @_);
unless (defined $pid)
{
die "$0: cannot fork: $!\n";
Modified: subversion/branches/1.7.x/contrib/hook-scripts/svn-keyword-check.pl
URL: http://svn.apache.org/viewvc/subversion/branches/1.7.x/contrib/hook-scripts/svn-keyword-check.pl?rev=1485487&r1=1485486&r2=1485487&view=diff
==============================================================================
--- subversion/branches/1.7.x/contrib/hook-scripts/svn-keyword-check.pl (original)
+++ subversion/branches/1.7.x/contrib/hook-scripts/svn-keyword-check.pl Wed May 22 23:10:27 2013
@@ -141,7 +141,7 @@ sub check {
return 1;
} else {
my @keywords = get_svnkeywords($file);
- my $fh = _pipe("$svnlook cat $flag $value $repos $file");
+ my $fh = _pipe($svnlook, qw/cat/, $flag, $value, $repos, '--', $file);
while (my $line = <$fh>) {
foreach my $keyword (@keywords) {
if ($line =~ m/$keyword/) {
@@ -168,7 +168,7 @@ sub file_is_binary {
return 0;
}
if (has_svn_property($file, "svn:mime-type")) {
- my ($mimetype) = read_from_process("$svnlook propget $flag $value $repos svn:mime-type $file");
+ my ($mimetype) = read_from_process($svnlook, qw/propget/, $flag, $value, $repos, 'svn:mime-type', '--', $file);
chomp($mimetype);
$mimetype =~ s/^\s*(.*)/$1/;
if ($mimetype =~ m/^text\//) {
@@ -186,7 +186,7 @@ sub file_is_binary {
# Return a list of svn:keywords on a file
sub get_svnkeywords {
my $file = shift;
- my @lines = read_from_process("$svnlook propget $flag $value $repos svn:keywords $file");
+ my @lines = read_from_process($svnlook, qw/propget/, $flag, $value, $repos, 'svn:keywords', '--', $file);
my @returnlines;
foreach my $line (@lines) {
$line =~ s/\s+/ /;
@@ -199,7 +199,7 @@ sub get_svnkeywords {
sub has_svn_property {
my $file = shift;
my $keyword = shift;
- my @proplist = read_from_process("$svnlook proplist $flag $value $repos $file");
+ my @proplist = read_from_process($svnlook, qw/proplist/, $flag, $value, $repos, '--', $file);
foreach my $prop (@proplist) {
chomp($prop);
if ($prop =~ m/\b$keyword\b/) {
@@ -241,7 +241,7 @@ sub safe_read_from_pipe {
# Return the filehandle as a glob so we can loop over it elsewhere.
sub _pipe {
local *SAFE_READ;
- my $pid = open(SAFE_READ, '-|');
+ my $pid = open(SAFE_READ, '-|', @_);
unless (defined $pid) {
die "$0: cannot fork: $!\n";
}
Propchange: subversion/branches/1.8.x/
------------------------------------------------------------------------------
Merged /subversion/trunk:r1485350
Modified: subversion/branches/1.8.x/STATUS
URL: http://svn.apache.org/viewvc/subversion/branches/1.8.x/STATUS?rev=1485487&r1=1485486&r2=1485487&view=diff
==============================================================================
--- subversion/branches/1.8.x/STATUS (original)
+++ subversion/branches/1.8.x/STATUS Wed May 22 23:10:27 2013
@@ -160,10 +160,3 @@ Approved changes:
# that would restart the soak should not be added unless they are resolving
# blocking issues. If in doubt see this link for details:
# http://subversion.apache.org/docs/community-guide/releasing.html#release-stabilization
-
- * r1485350
- contrib: fix some argument passing.
- Justification:
- More robust that way.
- Votes:
- +1: danielsh, stsp, breser
Modified: subversion/branches/1.8.x/contrib/hook-scripts/check-mime-type.pl
URL: http://svn.apache.org/viewvc/subversion/branches/1.8.x/contrib/hook-scripts/check-mime-type.pl?rev=1485487&r1=1485486&r2=1485487&view=diff
==============================================================================
--- subversion/branches/1.8.x/contrib/hook-scripts/check-mime-type.pl (original)
+++ subversion/branches/1.8.x/contrib/hook-scripts/check-mime-type.pl Wed May 22 23:10:27 2013
@@ -120,7 +120,7 @@ foreach my $path ( @files_added )
# Parse the complete list of property values of the file $path to extract
# the mime-type and eol-style
foreach my $prop (&read_from_process($svnlook, 'proplist', $repos, '-t',
- $txn, '--verbose', $path))
+ $txn, '--verbose', '--', $path))
{
if ($prop =~ /^\s*svn:mime-type : (\S+)/)
{
@@ -187,7 +187,7 @@ sub safe_read_from_pipe
croak "$0: safe_read_from_pipe passed no arguments.\n";
}
print "Running @_\n";
- my $pid = open(SAFE_READ, '-|');
+ my $pid = open(SAFE_READ, '-|', @_);
unless (defined $pid)
{
die "$0: cannot fork: $!\n";
Modified: subversion/branches/1.8.x/contrib/hook-scripts/svn-keyword-check.pl
URL: http://svn.apache.org/viewvc/subversion/branches/1.8.x/contrib/hook-scripts/svn-keyword-check.pl?rev=1485487&r1=1485486&r2=1485487&view=diff
==============================================================================
--- subversion/branches/1.8.x/contrib/hook-scripts/svn-keyword-check.pl (original)
+++ subversion/branches/1.8.x/contrib/hook-scripts/svn-keyword-check.pl Wed May 22 23:10:27 2013
@@ -141,7 +141,7 @@ sub check {
return 1;
} else {
my @keywords = get_svnkeywords($file);
- my $fh = _pipe("$svnlook cat $flag $value $repos $file");
+ my $fh = _pipe($svnlook, qw/cat/, $flag, $value, $repos, '--', $file);
while (my $line = <$fh>) {
foreach my $keyword (@keywords) {
if ($line =~ m/$keyword/) {
@@ -168,7 +168,7 @@ sub file_is_binary {
return 0;
}
if (has_svn_property($file, "svn:mime-type")) {
- my ($mimetype) = read_from_process("$svnlook propget $flag $value $repos svn:mime-type $file");
+ my ($mimetype) = read_from_process($svnlook, qw/propget/, $flag, $value, $repos, 'svn:mime-type', '--', $file);
chomp($mimetype);
$mimetype =~ s/^\s*(.*)/$1/;
if ($mimetype =~ m/^text\//) {
@@ -186,7 +186,7 @@ sub file_is_binary {
# Return a list of svn:keywords on a file
sub get_svnkeywords {
my $file = shift;
- my @lines = read_from_process("$svnlook propget $flag $value $repos svn:keywords $file");
+ my @lines = read_from_process($svnlook, qw/propget/, $flag, $value, $repos, 'svn:keywords', '--', $file);
my @returnlines;
foreach my $line (@lines) {
$line =~ s/\s+/ /;
@@ -199,7 +199,7 @@ sub get_svnkeywords {
sub has_svn_property {
my $file = shift;
my $keyword = shift;
- my @proplist = read_from_process("$svnlook proplist $flag $value $repos $file");
+ my @proplist = read_from_process($svnlook, qw/proplist/, $flag, $value, $repos, '--', $file);
foreach my $prop (@proplist) {
chomp($prop);
if ($prop =~ m/\b$keyword\b/) {
@@ -241,7 +241,7 @@ sub safe_read_from_pipe {
# Return the filehandle as a glob so we can loop over it elsewhere.
sub _pipe {
local *SAFE_READ;
- my $pid = open(SAFE_READ, '-|');
+ my $pid = open(SAFE_READ, '-|', @_);
unless (defined $pid) {
die "$0: cannot fork: $!\n";
}