slitaz-boot-scripts rev 45 1.6
Fix /dev perms, again
author | Pascal Bellard <pascal.bellard@slitaz.org> |
---|---|
date | Thu Mar 06 12:18:35 2008 +0000 (2008-03-06) |
parents | b816cb7cece4 |
children | 652e8f80501a |
files | etc/init.d/rcS |
line diff
1.1 --- a/etc/init.d/rcS Thu Mar 06 07:54:29 2008 +0000 1.2 +++ b/etc/init.d/rcS Thu Mar 06 12:18:35 2008 +0000 1.3 @@ -61,10 +61,11 @@ 1.4 # Add also /dev/cdrom to fstab if entry dos not exist. 1.5 # 1.6 DRIVE_NAME=`cat /proc/sys/dev/cdrom/info | grep "drive name" | cut -f 3` 1.7 -if [ ! "`readlink /dev/cdrom`" ]; then 1.8 +if [ -n "$DRIVE_NAME" -a ! "`readlink /dev/cdrom`" ]; then 1.9 echo -n "Creating symlink : /dev/cdrom..." 1.10 ln -s /dev/$DRIVE_NAME /dev/cdrom 1.11 chmod 0666 /dev/cdrom 1.12 + chmod 0666 /dev/$DRIVE_NAME 1.13 status 1.14 fi 1.15 if ! grep -q "/dev/cdrom" /etc/fstab; then 1.16 @@ -73,7 +74,6 @@ 1.17 >> /etc/fstab 1.18 status 1.19 fi 1.20 -[ -n "$DRIVE_NAME" ] && chmod 0666 /dev/$DRIVE_NAME 1.21 1.22 # Handle kernel cmdline parameter modprobe=<module_list> 1.23 if grep -q " modprobe=" /proc/cmdline; then