[readonly/geninitrd: 427/1068] - no need to interpolate vars in gen_devices()

draenog draenog at pld-linux.org
Sat Nov 2 19:48:15 CET 2013


commit 06ae4e5a2c82f5d1ec6a28549233b15488f16c85
Author: Elan Ruusamäe <glen at pld-linux.org>
Date:   Fri Oct 5 13:39:05 2007 +0000

    - no need to interpolate vars in gen_devices()
    
    svn-id: @8784

 geninitrd | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)
---
diff --git a/geninitrd b/geninitrd
index 6f3d919..808aff8 100755
--- a/geninitrd
+++ b/geninitrd
@@ -1178,13 +1178,13 @@ EOF
 # generates /dev nodes based on /proc/partitions information
 # needs /proc mounted
 initrd_gen_devices() {
-	cat <<-EOF >> "$s"
+	cat <<-'EOF' >> "$s"
 	: 'Making device nodes'
 	# ignore first two lines, header, empty line and process rest
 	cat /proc/partitions | (read b; read b; while read major minor blocks dev rest; do
-		node=/dev/\$dev
-		mkdir -p \${node%/*}
-		mknod \$node b \$major \$minor
+		node=/dev/$dev
+		mkdir -p ${node%/*}
+		mknod $node b $major $minor
 	done
 	)
 EOF
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/readonly/geninitrd.git/commitdiff/147754ca159d40ca5eb541074dc043d8cbd92090



More information about the pld-cvs-commit mailing list