From d1836f497ce53ccd2eb3ea2796832119f0db1b1d Mon Sep 17 00:00:00 2001 From: Stefan Seyfried Date: Sun, 22 Feb 2015 18:47:29 +0100 Subject: [PATCH] hdd_menu: fix device name on fdisk invocation --- src/gui/hdd_menu.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/gui/hdd_menu.cpp b/src/gui/hdd_menu.cpp index cf8670d72..7b0f4df6c 100644 --- a/src/gui/hdd_menu.cpp +++ b/src/gui/hdd_menu.cpp @@ -1048,7 +1048,7 @@ int CHDDMenuHandler::formatDevice(std::string dev) snprintf(cmd, sizeof(cmd), "%s -f -uM %s", sfdisk.c_str(), devname.c_str()); strcpy(cmd2, "0,\n;\n;\n;\ny\n"); } else if (! fdisk.empty()) { - snprintf(cmd, sizeof(cmd), "%s -u /dev/%s", fdisk.c_str(), devname.c_str()); + snprintf(cmd, sizeof(cmd), "%s -u %s", fdisk.c_str(), devname.c_str()); strcpy(cmd2, "o\nn\np\n1\n2048\n\nw\n"); } else { /* cannot do anything */