[ros-diffs] [cwittich] 22469: reverted the hdd "fix" from "Great Lord of code duplication" and changed it to hpoussin's proposal

cwittich at svn.reactos.org cwittich at svn.reactos.org
Wed Jun 21 18:23:43 CEST 2006


Author: cwittich
Date: Wed Jun 21 20:23:42 2006
New Revision: 22469

URL: http://svn.reactos.ru/svn/reactos?rev=22469&view=rev
Log:
reverted the hdd "fix" from "Great Lord of code duplication"
and changed it to hpoussin's proposal

Modified:
    trunk/tools/Qemu GUI/QEmu.cs

Modified: trunk/tools/Qemu GUI/QEmu.cs
URL: http://svn.reactos.ru/svn/reactos/trunk/tools/Qemu%20GUI/QEmu.cs?rev=22469&r1=22468&r2=22469&view=diff
==============================================================================
--- trunk/tools/Qemu GUI/QEmu.cs (original)
+++ trunk/tools/Qemu GUI/QEmu.cs Wed Jun 21 20:23:42 2006
@@ -169,18 +169,9 @@
             for (int i = 0; i < 4; i++)
             {
                 if (this.HDD[i].Enabled && (this.HDD[i].Path.Length > 0))
-                {
-                   if (i == 0)
-                       buffer += "-hda \"" + this.HDD[i].Path + "\" ";
-                   if (i == 1)
-                       buffer += "-hdb \"" + this.HDD[i].Path + "\" ";
-                   if (i == 2)
-                       buffer += "-hdc \"" + this.HDD[i].Path + "\" ";
-                   if (i == 3)
-                       buffer += "-hdd \""+ this.HDD[i].Path + "\" ";
-
-                }
-            }
+                   buffer += String.Format(@"-hd{0} ""{1}""", (char) ('a' + i), this.HDD[i].Path);
+            }
+            Console.WriteLine(buffer);
             return buffer;
         }
 




More information about the Ros-diffs mailing list