dfxml report was missing the first byte_run, fix it.

This commit is contained in:
Christophe Grenier 2011-04-28 10:06:52 +02:00
parent d2de73de31
commit 5118568923
2 changed files with 5 additions and 5 deletions

View file

@ -316,11 +316,11 @@ void xml_log_file_recovered(const file_recovery_t *file_recovery)
xml_pop("fileobject");
}
static void xml_log_file_recovered2_aux(const alloc_data_t *file, const uint64_t file_size)
static void xml_log_file_recovered2_aux(const alloc_data_t *space, const alloc_data_t *file, const uint64_t file_size)
{
struct td_list_head *tmp;
uint64_t size=0;
td_list_for_each(tmp, &file->list)
for(tmp=&file->list; tmp!=&space->list; tmp=tmp->next)
{
const alloc_data_t *element=td_list_entry(tmp, alloc_data_t, list);
if(size >= file_size)
@ -348,7 +348,7 @@ static void xml_log_file_recovered2_aux(const alloc_data_t *file, const uint64_t
}
}
void xml_log_file_recovered2(const file_recovery_t *file_recovery)
void xml_log_file_recovered2(const alloc_data_t *space, const file_recovery_t *file_recovery)
{
if(xml_handle==NULL)
return;
@ -358,7 +358,7 @@ void xml_log_file_recovered2(const file_recovery_t *file_recovery)
xml_out2s("filename", relative_name(file_recovery->filename));
xml_out2i("filesize", file_recovery->file_size);
xml_push("byte_runs", "");
xml_log_file_recovered2_aux(file_recovery->loc, file_recovery->file_size);
xml_log_file_recovered2_aux(space, file_recovery->loc, file_recovery->file_size);
xml_pop("byte_runs");
xml_pop("fileobject");
}

View file

@ -40,7 +40,7 @@ void xml_set_command_line(const int argc, char **argv);
void xml_add_DFXML_creator(const char *package, const char *version);
void xml_shutdown(void);
void xml_log_file_recovered(const file_recovery_t *file_recovery);
void xml_log_file_recovered2(const file_recovery_t *file_recovery);
void xml_log_file_recovered2(const alloc_data_t *space, const file_recovery_t *file_recovery);
void xml_printf(const char *__restrict __format,...) __attribute__((format(printf,1,2)));
#ifdef __cplusplus
} /* closing brace for extern "C" */