More timely abort of find jobs if the result pager gets aborted

This commit is contained in:
Thomas Schmitt 2009-08-14 10:22:59 +00:00
parent 4d1d3732be
commit 11fe78ffb1
3 changed files with 16 additions and 6 deletions

View File

@ -9855,6 +9855,9 @@ int Xorriso_findx(struct XorrisO *xorriso, struct FindjoB *job,
char *name= NULL, *path= NULL, *sfe= NULL;
char *abs_dir_path_data= NULL, *abs_path= NULL;
if(xorriso->request_to_abort)
{ret= 0; goto ex;}
sfe= malloc(5*SfileadrL);
name= malloc(SfileadrL);
path= malloc(SfileadrL);
@ -9901,9 +9904,9 @@ int Xorriso_findx(struct XorrisO *xorriso, struct FindjoB *job,
if(ret>0) {
ret= Xorriso_findx_action(xorriso, job, abs_dir_path, dir_path, depth,
flag&1);
if(ret<=0) {
if(xorriso->request_to_abort)
goto ex;
{ret= 0; goto ex;}
if(ret<=0) {
if(Xorriso_eval_problem_status(xorriso, ret, 1|2)<0)
goto ex;
}
@ -9963,9 +9966,9 @@ int Xorriso_findx(struct XorrisO *xorriso, struct FindjoB *job,
goto ex;
if(ret>0) {
ret= Xorriso_findx_action(xorriso, job, abs_path, path, depth, flag&1);
if(ret<=0) {
if(xorriso->request_to_abort)
goto ex;
{ret= 0; goto ex;}
if(ret<=0) {
if(Xorriso_eval_problem_status(xorriso, ret, 1|2)<0)
goto ex;
}

View File

@ -1 +1 @@
#define Xorriso_timestamP "2009.08.13.203718"
#define Xorriso_timestamP "2009.08.14.102355"

View File

@ -7870,6 +7870,9 @@ int Xorriso_findi(struct XorrisO *xorriso, struct FindjoB *job,
int node_count, node_idx;
char *path= NULL, *abs_path= NULL;
if(xorriso->request_to_abort)
{ret= 0; goto ex;}
path= malloc(SfileadrL);
abs_path= malloc(SfileadrL);
if(path==NULL || abs_path==NULL) {
@ -7928,6 +7931,8 @@ int Xorriso_findi(struct XorrisO *xorriso, struct FindjoB *job,
flag&(1|2));
if(ret<=0)
goto ex;
if(xorriso->request_to_abort)
{ret= 0; goto ex;}
if(ret==2) {
/* re-determine dir_node in case it has a new persona */
ret= Xorriso_node_from_path(xorriso, volume, path, &iso_node, 1);
@ -7968,7 +7973,7 @@ int Xorriso_findi(struct XorrisO *xorriso, struct FindjoB *job,
&node_array, &node_count, &node_idx, &node, 0);
if(ret<0)
goto ex;
if(ret==0 || xorriso->request_to_abort)
if(ret==0)
break;
name= (char *) iso_node_get_name(node);
ret= Xorriso_make_abs_adr(xorriso, dir_path, name, path, 4);
@ -7999,6 +8004,8 @@ int Xorriso_findi(struct XorrisO *xorriso, struct FindjoB *job,
goto ex;
ret= Xorriso_findi_action(xorriso, job, iter, mem,
abs_path, path, node, depth, 1|(flag&2));
if(xorriso->request_to_abort)
{ret= 0; goto ex;}
if(ret==2) { /* node has been deleted */
/* re-determine node in case it has a new persona */
if(volume==NULL) {