1 |
vapier 12/01/04 05:57:19 |
2 |
|
3 |
Modified: portability.eclass |
4 |
Log: |
5 |
add missing "local" markings for variables |
6 |
|
7 |
Revision Changes Path |
8 |
1.24 eclass/portability.eclass |
9 |
|
10 |
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/portability.eclass?rev=1.24&view=markup |
11 |
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/portability.eclass?rev=1.24&content-type=text/plain |
12 |
diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/portability.eclass?r1=1.23&r2=1.24 |
13 |
|
14 |
Index: portability.eclass |
15 |
=================================================================== |
16 |
RCS file: /var/cvsroot/gentoo-x86/eclass/portability.eclass,v |
17 |
retrieving revision 1.23 |
18 |
retrieving revision 1.24 |
19 |
diff -u -r1.23 -r1.24 |
20 |
--- portability.eclass 27 Dec 2011 17:55:12 -0000 1.23 |
21 |
+++ portability.eclass 4 Jan 2012 05:57:19 -0000 1.24 |
22 |
@@ -1,6 +1,6 @@ |
23 |
# Copyright 1999-2011 Gentoo Foundation |
24 |
# Distributed under the terms of the GNU General Public License v2 |
25 |
-# $Header: /var/cvsroot/gentoo-x86/eclass/portability.eclass,v 1.23 2011/12/27 17:55:12 fauli Exp $ |
26 |
+# $Header: /var/cvsroot/gentoo-x86/eclass/portability.eclass,v 1.24 2012/01/04 05:57:19 vapier Exp $ |
27 |
# |
28 |
# Author: Diego Pettenò <flameeyes@g.o> |
29 |
# |
30 |
@@ -15,11 +15,11 @@ |
31 |
# |
32 |
# mimic cp --parents copy, but working on BSD userland as well |
33 |
treecopy() { |
34 |
- dest=${!#} |
35 |
- files_count=$# |
36 |
+ local dest=${!#} |
37 |
+ local files_count=$# |
38 |
|
39 |
- while(( $# > 1 )); do |
40 |
- dirstruct=$(dirname "$1") |
41 |
+ while (( $# > 1 )); do |
42 |
+ local dirstruct=$(dirname "$1") |
43 |
mkdir -p "${dest}/${dirstruct}" |
44 |
cp -pPR "$1" "${dest}/${dirstruct}" |
45 |
|
46 |
@@ -38,6 +38,7 @@ |
47 |
return $? |
48 |
fi |
49 |
|
50 |
+ local min max step |
51 |
case $# in |
52 |
1) min=1 max=$1 step=1 ;; |
53 |
2) min=$1 max=$2 step=1 ;; |