dump 0.4b44 incorrectly reports percentages when dumping to file
Bug #1478265 reported by
John Ioannidis
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
dump (Ubuntu) |
New
|
Undecided
|
Unassigned |
Bug Description
While dumping a 6TB ext4 filesystem onto a single file, I saw reports such as
after most of the filesystem had been dumped. Obviously this pointed to an integer overflow, and sure enough, the global variable "blockswritten" is an int, not a long long. This should fix it, although I don't have time to test it with a 6TB filesystem right now :)
$ diff dump/main.c dump/main.c.orig
136c136
< long long blockswritten;/* number of blocks written on current tape */
---
> int blockswritten; /* number of blocks written on current tape */
Also: any idea why the original code uses signed numbers? blockswritten, bytes_written, and tapesize should all be unsigned long long.
To post a comment you must log in.