summaryrefslogtreecommitdiff
path: root/gdisk.cc
diff options
context:
space:
mode:
authorsrs5694 <srs5694@users.sourceforge.net>2010-03-19 14:21:59 -0400
committersrs5694 <srs5694@users.sourceforge.net>2010-03-19 14:21:59 -0400
commita8582cfe6c1aa5e5f80458ac72d881a04ae0ba44 (patch)
tree93cbbc9e8013e2404ab2fe7740eccdf28dc966cf /gdisk.cc
parent55d926192adc984462509b2966e23bc0d1129bbd (diff)
downloadsgdisk-a8582cfe6c1aa5e5f80458ac72d881a04ae0ba44.tar.gz
Changes to sector alignment policies and behavior when restoring a
backup fails
Diffstat (limited to 'gdisk.cc')
-rw-r--r--gdisk.cc7
1 files changed, 5 insertions, 2 deletions
diff --git a/gdisk.cc b/gdisk.cc
index fc0355c..a3e4bb9 100644
--- a/gdisk.cc
+++ b/gdisk.cc
@@ -318,6 +318,7 @@ void ExpertsMenu(string filename, GPTDataTextUI* theGPT) {
uint32_t pn, temp1, temp2;
int goOn = 1;
GUIDData aGUID;
+ ostringstream prompt;
do {
cout << "\nExpert command (? for help): ";
@@ -355,8 +356,10 @@ void ExpertsMenu(string filename, GPTDataTextUI* theGPT) {
theGPT->ShowDetails();
break;
case 'l': case 'L':
- temp1 = GetNumber(1, 128, 8, (string)
- "Enter the sector alignment value (1-128, default = 8): ");
+ prompt.seekp(0);
+ prompt << "Enter the sector alignment value (1-" << MAX_ALIGNMENT << ", default = "
+ << DEFAULT_ALIGNMENT << "): ";
+ temp1 = GetNumber(1, MAX_ALIGNMENT, DEFAULT_ALIGNMENT, prompt.str());
theGPT->SetAlignment(temp1);
break;
case 'm': case 'M':