summaryrefslogtreecommitdiffstats
path: root/fdisks/fdisk.c
diff options
context:
space:
mode:
authorKarel Zak2012-07-09 22:26:27 +0200
committerKarel Zak2012-07-09 22:26:27 +0200
commit657d9adb71ed50275b1ed2a0d4e966032db5ba97 (patch)
tree071fa200585354a29f51d1e0cf51baa5b4b9ba4e /fdisks/fdisk.c
parentutmpdump: white space fix (diff)
downloadkernel-qcow2-util-linux-657d9adb71ed50275b1ed2a0d4e966032db5ba97.tar.gz
kernel-qcow2-util-linux-657d9adb71ed50275b1ed2a0d4e966032db5ba97.tar.xz
kernel-qcow2-util-linux-657d9adb71ed50275b1ed2a0d4e966032db5ba97.zip
fix buffer overrun in some calls to sscanf
Reported-by: Sergei Antonov <saproj@gmail.com> Signed-off-by: Karel Zak <kzak@redhat.com>
Diffstat (limited to 'fdisks/fdisk.c')
-rw-r--r--fdisks/fdisk.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/fdisks/fdisk.c b/fdisks/fdisk.c
index 748badf47..4d5ab02ce 100644
--- a/fdisks/fdisk.c
+++ b/fdisks/fdisk.c
@@ -1819,7 +1819,7 @@ static void
print_all_partition_table_from_option(unsigned long sector_size)
{
FILE *procpt;
- char line[128], ptname[128], devname[256];
+ char line[128 + 1], ptname[128 + 1], devname[256];
int ma, mi;
unsigned long long sz;