summaryrefslogtreecommitdiffstats
path: root/src/godmode.c
diff options
context:
space:
mode:
authorChristophe Grenier <grenier@cgsecurity.org>2016-09-13 20:07:30 +0200
committerChristophe Grenier <grenier@cgsecurity.org>2016-09-13 20:07:30 +0200
commit8238ff4db4c5cd12f4d088eef979b310dda8008d (patch)
treefc2b859cc6bc9fd1e19ae8c1505d96d73ed291ee /src/godmode.c
parent0204d976c961a7555bf71615249afe31b92173cf (diff)
Cast to long long integer to avoid erronous progression report in search_part()
This issue seems to affect Mac OS X. See bug report: https://github.com/cgsecurity/testdisk/issues/12
Diffstat (limited to 'src/godmode.c')
-rw-r--r--src/godmode.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/godmode.c b/src/godmode.c
index 2f2e588..63771a7 100644
--- a/src/godmode.c
+++ b/src/godmode.c
@@ -623,9 +623,9 @@ static list_part_t *search_part(disk_t *disk_car, const list_part_t *list_part_o
{
wmove(stdscr,ANALYSE_Y,ANALYSE_X);
wclrtoeol(stdscr);
- wprintw(stdscr,"Analyse sector %11llu/%lu: %02u%%",
- search_location / disk_car->sector_size,
- (disk_car->disk_size-1)/disk_car->sector_size,
+ wprintw(stdscr,"Analyse sector %11llu/%llu: %02u%%",
+ (long long unsigned)(search_location / disk_car->sector_size),
+ (long long unsigned)((disk_car->disk_size-1)/disk_car->sector_size),
(unsigned int)(search_location*100/disk_car->disk_size));
wrefresh(stdscr);
switch(check_enter_key_or_s(stdscr))