Fix the "cannot open /dev/scd0: No medium found" issue
authorMichael Prokop <mika@grml.org>
Sat, 15 Nov 2008 12:47:40 +0000 (13:47 +0100)
committerMichael Prokop <mika@grml.org>
Sat, 15 Nov 2008 12:47:40 +0000 (13:47 +0100)
debian/changelog
debian/patches/00list
debian/patches/04_fix_no_medium_found_error.dpatch [new file with mode: 0755]

index 0e5c4a3..7dce953 100644 (file)
@@ -5,8 +5,9 @@ live-initramfs (1.139.1-4grml.01) unstable; urgency=low
   [ Michael Prokop ]
   * Ignore errors from fstype.
   * Display "Mounted live system on ..." during bootup.
+  * Fix the "cannot open /dev/scd0: No medium found" issue.
 
- -- Michael Prokop <mika@grml.org>  Sat, 15 Nov 2008 00:54:10 +0100
+ -- Michael Prokop <mika@grml.org>  Sat, 15 Nov 2008 11:46:23 +0100
 
 live-initramfs (1.139.1-2grml.01) unstable; urgency=low
 
index af077af..8ef5a62 100644 (file)
@@ -1,4 +1,5 @@
 01_add_rsync.dpatch
 02_more_verbose_toram.dpatch
 03_grml_version_file_hook.dpatch
+04_fix_no_medium_found_error.dpatch
 05_boot_failure_message_grml.dpatch
diff --git a/debian/patches/04_fix_no_medium_found_error.dpatch b/debian/patches/04_fix_no_medium_found_error.dpatch
new file mode 100755 (executable)
index 0000000..fba7181
--- /dev/null
@@ -0,0 +1,22 @@
+#! /bin/sh /usr/share/dpatch/dpatch-run
+## 04_fix_no_medium_found_error.dpatch <mika@grml.org>
+##
+## All lines beginning with `## DP:' are a description of the patch.
+## DP: Fix the "cannot open /dev/scd0: No medium found" issue
+
+@DPATCH@
+
+--- a/scripts/live-helpers
++++ b/scripts/live-helpers
+@@ -77,9 +77,9 @@ get_fstype ()
+           return
+       fi
+-      eval $(fstype < ${1} 2>/dev/null)
++      eval $(fstype ${1} 2>/dev/null)
+-      if [ "${FSTYPE}" != "unknown" ]
++      if [ "${FSTYPE}" != "unknown" -a -n "${FSTYPE}" ]
+       then
+               echo ${FSTYPE}
+               return 0