- Timestamp:
- May 20, 2010, 10:03:31 AM (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/PS-IPP-PStamp/lib/PS/IPP/PStamp/RequestFile.pm
r27900 r28048 17 17 our @EXPORT_OK = qw( 18 18 read_request_file 19 get_error_string 19 20 $PSTAMP_CENTER_IN_PIXELS 20 21 $PSTAMP_RANGE_IN_PIXELS … … 82 83 our $PSTAMP_NO_OVERLAP = 28; 83 84 85 84 86 use IPC::Cmd 0.36 qw( can_run run ); 85 87 86 88 use PS::IPP::Metadata::List qw( parse_md_list ); 87 89 use PS::IPP::Config qw( :standard ); 90 91 my @errorStrings = qw( 92 PSTAMP_SUCCESS 93 PS_EXIT_UNKNOWN_ERROR 94 PS_EXIT_SYS_ERROR 95 PS_EXIT_CONFIG_ERROR 96 PS_EXIT_PROG_ERROR 97 PS_EXIT_DATA_ERROR 98 PS_EXIT_TIMEOUT_ERROR 99 undefined 100 undefined 101 undefined 102 PSTAMP_SYSTEM_ERROR 103 PSTAMP_NOT_IMPLEMENTED 104 PSTAMP_UNKNOWN_ERROR 105 undefined 106 undefined 107 undefined 108 undefined 109 undefined 110 undefined 111 undefined 112 PSTAMP_DUP_REQUEST 113 PSTAMP_INVALID_REQUEST 114 PSTAMP_UNKNOWN_PRODUCT 115 PSTAMP_NO_IMAGE_MATCH 116 PSTAMP_NOT_DESTREAKED 117 PSTAMP_NOT_AVAILABLE 118 PSTAMP_GONE 119 PSTAMP_NO_JOBS_QUEUED 120 PSTAMP_NO_OVERLAP 121 ); 88 122 89 123 sub read_request_file { … … 205 239 } 206 240 241 sub get_error_string { 242 my $error_code = shift; 243 my $error_string; 244 if ($error_code >= 0) { 245 $error_string = $errorStrings[$error_code]; 246 } 247 $error_string = "unknown" if !$error_string; 248 return $error_string; 249 } 250 207 251 1;
Note:
See TracChangeset
for help on using the changeset viewer.
