summaryrefslogtreecommitdiffstats
path: root/src/sessionp.c
diff options
context:
space:
mode:
authorChristophe Grenier <grenier@cgsecurity.org>2013-03-24 19:49:37 +0100
committerChristophe Grenier <grenier@cgsecurity.org>2013-03-24 19:49:37 +0100
commit8dfd9a7a4630a3d5c993f21ac7f9e8678a171d8c (patch)
treee1cf352e81adfd324e2f625a0187dd2b6aac3666 /src/sessionp.c
parent8b9047aa4e1c8e07823b32a62973769a05733673 (diff)
PhotoRec: save current progress every 5 minutes
Diffstat (limited to 'src/sessionp.c')
-rw-r--r--src/sessionp.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/sessionp.c b/src/sessionp.c
index a3ff8c4..0abfcec 100644
--- a/src/sessionp.c
+++ b/src/sessionp.c
@@ -67,7 +67,7 @@ int session_load(char **cmd_device, char **current_cmd, alloc_data_t *list_free_
if(!f_session)
{
log_info("Can't open photorec.ses file: %s\n",strerror(errno));
- session_save(NULL, NULL, NULL, 0);
+ session_save(NULL, NULL, NULL);
return -1;
}
if(fstat(fileno(f_session), &stat_rec)<0)
@@ -158,7 +158,7 @@ int session_load(char **cmd_device, char **current_cmd, alloc_data_t *list_free_
}
}
-int session_save(alloc_data_t *list_free_space, struct ph_param *params, const struct ph_options *options, const unsigned int carve_free_space_only)
+int session_save(alloc_data_t *list_free_space, struct ph_param *params, const struct ph_options *options)
{
FILE *f_session;
f_session=fopen(SESSION_FILENAME,"wb");
@@ -248,7 +248,7 @@ int session_save(alloc_data_t *list_free_space, struct ph_param *params, const
if(options->lowmem>0)
fprintf(f_session, "lowmem,");
/* Save options - End */
- if(carve_free_space_only>0)
+ if(params->carve_free_space_only>0)
fprintf(f_session,"freespace,");
else
fprintf(f_session,"wholespace,");