Author: janderwald
Date: Mon Sep 3 20:02:26 2007
New Revision: 28819
URL:
http://svn.reactos.org/svn/reactos?rev=28819&view=rev
Log:
- improve error checking
Modified:
trunk/reactos/tools/sysreg/rosboot_test.cpp
Modified: trunk/reactos/tools/sysreg/rosboot_test.cpp
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/tools/sysreg/rosboot_test.…
==============================================================================
--- trunk/reactos/tools/sysreg/rosboot_test.cpp (original)
+++ trunk/reactos/tools/sysreg/rosboot_test.cpp Mon Sep 3 20:02:26 2007
@@ -261,17 +261,25 @@
#endif
- m_BootCmd = m_EmuPath + _T(" -L ") + qemudir + _T(" -m ") +
m_MaxMem + _T(" -hda ") + m_HDDImage + _T(" -serial ") + pipe;
+ m_BootCmd = m_EmuPath + _T(" -L ") + qemudir + _T(" -m ") +
m_MaxMem + _T(" -serial ") + pipe;
if (m_CDImage.length())
{
/* boot from cdrom */
m_BootCmd += _T(" -boot d -cdrom ") + m_CDImage;
}
+ else if (m_HDDImage.length ())
+ {
+ /* boot from hdd */
+ m_BootCmd += _T(" -boot c -hda ") + m_HDDImage;
+ }
else
{
- /* boot from hdd */
- m_BootCmd += _T(" -boot c ");
+ /*
+ * no boot device provided
+ */
+ cerr << "Error: no bootdevice provided" << endl;
+ return false;
}
#ifdef __LINUX__