IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Mar 17, 2009, 12:08:50 PM (17 years ago)
Author:
beaumont
Message:

merged with head

Location:
branches/cnb_branches/cnb_branch_20090301
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • branches/cnb_branches/cnb_branch_20090301

  • branches/cnb_branches/cnb_branch_20090301/ippScripts/scripts/magic_destreak.pl

    r22430 r23352  
    2121
    2222use PS::IPP::Config 1.01 qw( :standard );
    23 
    24 my $ipprc = PS::IPP::Config->new(); # IPP configuration
    2523
    2624use Getopt::Long qw( GetOptions :config auto_help auto_version gnu_getopt );
     
    7674    defined $outroot;
    7775
    78 # Unhandled exceptions should be passed on to my_die so they get pushed into the database
    79 $SIG{__DIE__} = sub { die @_ if $^S;
    80                       my_die( $_[0], $magic_ds_id, $component, $PS_EXIT_UNKNOWN_ERROR ); };
    81 
     76my $ipprc = PS::IPP::Config->new( $camera ) or my_die( "Unable to set up", $magic_ds_id, $component, $PS_EXIT_CONFIG_ERROR ); # IPP configuration
     77$ipprc->redirect_output($logfile) or my_die( "Unable to redirect output", $magic_ds_id, $component, $PS_EXIT_SYS_ERROR ) if $logfile;
    8278
    8379my ($skycell_args, $class_id, $skycell_id);
     
    9490    &my_die("Invalid value for stage: $stage", $magic_ds_id, $component, $PS_EXIT_CONFIG_ERROR);
    9591}
    96 
    97 $ipprc->redirect_output($logfile) if $logfile;
    98 
    99 $ipprc->define_camera($camera);
    100 
    10192
    10293my $mdcParser = PS::IPP::Metadata::Config->new; # Parser for metadata config files
     
    276267    my $exit_code = shift;      # Exit code to add
    277268
     269    $exit_code = $PS_EXIT_PROG_ERROR unless defined $exit_code;
     270
    278271    my $command = "$magicdstool -adddestreakedfile";
    279272    $command   .= " -magic_ds_id $magic_ds_id";
Note: See TracChangeset for help on using the changeset viewer.