Project

General

Profile

« Previous | Next » 

Revision 9441

lib/sh/util.sh: die_e(): use die(), which performs the necessary save_e/rethrow. this requires using $? instead of $e for the exit status, because $e has not yet been set.

View differences:

lib/sh/util.sh
282 282
{ save_e; kw_params type; "log_${type:-err}" "$1"; rethrow; }
283 283

  
284 284
die_e() # usage: cmd || die_e [|| handle error]
285
{ save_e; log_err "command exited with error $e"; rethrow; }
285
{ die "command exited with error $?"; }
286 286

  
287 287

  
288 288
#### functions

Also available in: Unified diff