emulator: fixed bugs in get_drive_image_file()
authorSeokYeon Hwang <syeon.hwang@samsung.com>
Tue, 12 May 2015 04:29:12 +0000 (13:29 +0900)
committerSeokYeon Hwang <syeon.hwang@samsung.com>
Fri, 12 Jun 2015 10:05:57 +0000 (19:05 +0900)
Change-Id: I3b7169785499086c32ff9588acfb26a921f180f2
(cherry picked from commit 77a44857588e0ad46287ae30e1226bb1714b0d8a)
Signed-off-by: Sooyoung Ha <yoosah.ha@samsung.com>
tizen/src/emul_state.c

index fb183fff9c6e565948611173f2e7ec5bb5d69111..1324825a12d27a28d69bbe481ff65134fd05a2bb 100644 (file)
@@ -357,7 +357,7 @@ const char* get_drive_image_file(void)
 {
     char *drive_image_file = get_variable("drive_image_file");
 
-    if (!drive_image_file) {
+    if (drive_image_file) {
         return drive_image_file;
     }
 
@@ -366,7 +366,7 @@ const char* get_drive_image_file(void)
     BlockBackend *bb = blk_by_name("drive");
     if (bb) {
         BlockDriverState *bs = blk_bs(bb);
-        set_variable("drivce_image_file", bs->filename, true);
+        set_variable("drive_image_file", bs->filename, true);
 
         return bs->filename;
     }