summaryrefslogtreecommitdiffstats
path: root/src/phmain.c
diff options
context:
space:
mode:
authorChristophe Grenier <grenier@cgsecurity.org>2019-12-10 20:57:57 +0100
committerChristophe Grenier <grenier@cgsecurity.org>2019-12-10 20:57:57 +0100
commitac95883e2216cae52285b72dbdda9d443f9894ea (patch)
treeb0c536dcd23395f3577c267fb51e126c6293f93a /src/phmain.c
parent8a91bdfbfd5dc9124ad5fb1a7beda5a8ebcf5b97 (diff)
"photorec /d recup_dir /cmd resume" can be used to resume a sessionHEADmaster
automatically. If no session is available, prompt the user. See https://github.com/cgsecurity/testdisk/issues/73
Diffstat (limited to 'src/phmain.c')
-rw-r--r--src/phmain.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/phmain.c b/src/phmain.c
index 2205ceb..cbba88e 100644
--- a/src/phmain.c
+++ b/src/phmain.c
@@ -245,6 +245,10 @@ int main( int argc, char **argv )
}
else if((strcmp(argv[i],"/nosetlocale")==0) || (strcmp(argv[i],"-nosetlocale")==0))
run_setlocale=0;
+ else if(i+1 <= argc && strcmp(argv[i],"/cmd")==0 && strcmp(argv[i+1],"resume")==0)
+ {
+ params.cmd_device=argv[++i];
+ }
else if(strcmp(argv[i],"/cmd")==0)
{
if(i+2>=argc)