summaryrefslogtreecommitdiffstats
path: root/src/photorec.c
diff options
context:
space:
mode:
authorChristophe Grenier <grenier@cgsecurity.org>2011-04-03 18:19:15 +0200
committerChristophe Grenier <grenier@cgsecurity.org>2011-04-03 18:19:15 +0200
commit43f2bda4a4ad83a3f70cd8fb074e2e3485572518 (patch)
treed430a2e2657bc776df2dcf96c4a942c1453ee94e /src/photorec.c
parentd2b82238adbdbc31a29a89ff6ed6086a22b03463 (diff)
PhotoRec: remove useless log_info()
Diffstat (limited to 'src/photorec.c')
-rw-r--r--src/photorec.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/src/photorec.c b/src/photorec.c
index 73b310c..6d2a30f 100644
--- a/src/photorec.c
+++ b/src/photorec.c
@@ -344,19 +344,19 @@ int get_prev_file_header(alloc_data_t *list_search_space, alloc_data_t **current
alloc_data_t *file_space=*current_search_space;
uint64_t size=0;
/* Search backward the first fragment of a file not successfully recovered
- * Limit the search to 10 fragments and 1GB */
- for(nbr=0;nbr<10 && size<(uint64_t)1024*1024*1024;nbr++)
+ * Limit the search to 10 fragments or 1GB */
+ for(nbr=0; nbr<10 && size < (uint64_t)1024*1024*1024; nbr++)
{
file_space=td_list_entry(file_space->list.prev, alloc_data_t, list);
if(file_space==list_search_space)
return -1;
+ size+=file_space->end - file_space->start + 1;
if(file_space->file_stat!=NULL)
{
*current_search_space=file_space;
*offset=file_space->start;
return 0;
}
- size+=file_space->end - file_space->start + 1;
}
return -1;
}
@@ -868,7 +868,6 @@ static alloc_data_t *file_error_aux(alloc_data_t *space, alloc_data_t *file, con
new_element=td_list_entry(next, alloc_data_t, list);
if(element->end+1==new_element->start && new_element->file_stat==NULL)
{
- log_info("GOT IT\n");
new_element->start-=file_size_on_disk - size;
element->end=new_element->start - 1;
return new_element;