slitaz-boot-scripts rev 207
Avoid an error message if no cdrom
author | Pascal Bellard <pascal.bellard@slitaz.org> |
---|---|
date | Thu Apr 15 18:13:41 2010 +0200 (2010-04-15) |
parents | bb7387c4767e |
children | 28a1f75bbe37 |
files | etc/init.d/rcS |
line diff
1.1 --- a/etc/init.d/rcS Wed Apr 07 20:56:00 2010 +0200 1.2 +++ b/etc/init.d/rcS Thu Apr 15 18:13:41 2010 +0200 1.3 @@ -115,7 +115,7 @@ 1.4 if [ -n "$CDROM" ]; then 1.5 DRIVE_NAME=${CDROM#/dev/} 1.6 else 1.7 - DRIVE_NAME=`cat /proc/sys/dev/cdrom/info | grep "drive name" | cut -f 3` 1.8 + DRIVE_NAME=`grep -s "drive name" /proc/sys/dev/cdrom/info | cut -f 3` 1.9 fi 1.10 if [ -n "$DRIVE_NAME" -a ! "`readlink /dev/cdrom`" ]; then 1.11 echo -n "Creating symlink : /dev/cdrom..."