Project

General

Profile

« Previous | Next » 

Revision 12694

bugfix: lib/runscripts/util.run: gateway(): need to use is_callable() rather than func_exists() to check whether the target exists, because external commands (eg. echo) are supported as targets, too

View differences:

util.run
36 36
fallback() { echo_func; "$@"; } # overridable handler for targets w/o function
37 37

  
38 38
gateway() # overridable handler for *all* targets
39
{ echo_func; if func_exists "$1"; then "$@"; else fallback "$@"; fi; }
39
{ echo_func; if is_callable "$1"; then "$@"; else fallback "$@"; fi; }
40 40

  
41 41
run_args_cmd() # runs the command line args command
42 42
{

Also available in: Unified diff