Package: gdisk
Version: 0.8.1-1+b1
Severity: normal
Tags: patch upstream

simple test case
gdisk /dev/sda

GPT fdisk (gdisk) version 0.8.1

Partition table scan:
  MBR: protective
  BSD: not present
  APM: not present
  GPT: present

Found valid GPT with protective MBR; using GPT.

Command (? for help):

-> ctrl + d

Command (? for help):
Command (? for help):
Command (? for help):
Command (? for help):
Command (? for help):
Command (? for help):
Command (? for help):
Command (? for help):
Command (? for help):
Command (? for help):
Command (? for help):
Command (? for help):
.....

attached patch checks for eof on stdin, other parts of code may need same fix
but I only suspect here:
../basicmbr.cc:      switch (ReadString()[0]) {


-- System Information:
Debian Release: wheezy/sid
  APT prefers unstable
  APT policy: (500, 'unstable')
Architecture: amd64 (x86_64)

Kernel: Linux 2.6.32-5-xen-amd64 (SMP w/8 CPU cores)
Locale: LANG=C, LC_CTYPE=C (charmap=ANSI_X3.4-1968)
Shell: /bin/sh linked to /bin/bash

Versions of packages gdisk depends on:
ii  groff-base   1.21-6
ii  libc6        2.13-26
ii  libgcc1      1:4.6.2-15
ii  libicu48     <none>
ii  libncurses5  5.9-4
ii  libpopt0     1.16-3
ii  libstdc++6   4.6.2-15
ii  libtinfo5    5.9-4
ii  libuuid1     2.20.1-1.2

gdisk recommends no packages.

gdisk suggests no packages.
--- gdisk-0.8.1.orig/gpttext.cc	2011-10-01 23:52:33.000000000 +0200
+++ gdisk-0.8.1/gpttext.cc	2012-02-22 06:02:41.285287856 +0100
@@ -513,6 +513,7 @@
       cout << "\nCommand (? for help): ";
       switch (ReadString()[0]) {
          case '\0':
+            goOn = !cin.eof();
             break;
          case 'b': case 'B':
             cout << "Enter backup filename to save: ";

Reply via email to