X-Git-Url: http://dxcluster.net/gitweb/gitweb.cgi?a=blobdiff_plain;f=perl%2FDXCommandmode.pm;h=bcf1bf075b9beda9f40279bb70b59fbcf4f5e008;hb=c83b1ca22765fc07e5adcdc8dac24cbd066c9b95;hp=0f45213596374b5da4c7f585f3bf730906a413dc;hpb=17b1614af3840c2c74bee181290eb094f8ed4a00;p=spider.git diff --git a/perl/DXCommandmode.pm b/perl/DXCommandmode.pm index 0f452135..bcf1bf07 100644 --- a/perl/DXCommandmode.pm +++ b/perl/DXCommandmode.pm @@ -1335,11 +1335,16 @@ sub spawn_cmd sub { my $subpro = shift; if (isdbg('progress')) { - my $s = qq{line: "$line"}; + my $s = qq{$call line: "$line"}; $s .= ", args: " . join(', ', map { defined $_ ? qq{'$_'} : q{'undef'} } @$args) if $args && @$args; dbg($s); } - eval { @out = $cmdref->(@$args); }; + eval { + ++$self->{_in_sub_process}; + dbg "\$self->{_in_sub_process} = $self->{_in_sub_process}"; + @out = $cmdref->(@$args); + --$self->{_in_sub_process} if $self->{_in_sub_process} > 0; + }; if ($@) { DXDebug::dbgprintring(25); push @out, DXDebug::shortmess($@);