Use newly-added had_an_exception function where it seems appropriate.

wilder
Michael Pyne 12 years ago
parent 87bdd66fa2
commit 488f600ff3
  1. 4
      kdesrc-build
  2. 2
      modules/ksb/Module.pm
  3. 2
      modules/ksb/ModuleSet/KDEProjects.pm
  4. 2
      modules/ksb/Updater/Svn.pm

@ -237,8 +237,8 @@ eval
if (my $err = $@)
{
if (ref $err && $err->isa('ksb::BuildException')) {
print $err->{'exception_type'}, " error: ", $err->{'message'}, "\n";
if (had_an_exception()) {
print "kdesrc-build encountered an exceptional error condition: $err\n";
print "\tCan't continue, so stopping now.\n";
if ($err->{'exception_type'} eq 'Internal') {

@ -757,7 +757,7 @@ sub update
{
my $reason = ksb::IPC::MODULE_FAILURE;
if (ref $@ && $@->isa('ksb::BuildException')) {
if (had_an_exception()) {
if ($@->{'exception_type'} eq 'ConflictPresent') {
$reason = ksb::IPC::MODULE_CONFLICT;
}

@ -211,7 +211,7 @@ sub convertToModules
};
if ($@) {
die $@ if ref $@; # Forward exception objects up
die $@ if had_an_exception(); # Forward exception objects up
croak_runtime("The XML for the KDE Project database could not be understood: $@");
}

@ -426,7 +426,7 @@ sub update_module_path
my $count = eval { $self->run_svn('svn-up', \@args); };
# Update failed, try svn cleanup.
if ($@ && $@->{exception_type} ne 'ConflictPresent')
if (had_an_exception() && $@->{exception_type} ne 'ConflictPresent')
{
info ("\tUpdate failed, trying a cleanup.");
my $result = safe_system('svn', 'cleanup');

Loading…
Cancel
Save