Problem:
A customer had a script called (say) ggg, and a program (say) ggg.cbl. The script was in a directory pointed at by PATH, and the program was in a directory pointed at by COBPATH. If he typed 'anim ggg', then Animator picked up the script, rather than the program. Why was this?
Resolution:
Animator can debug .int, .gnt, .so, executables, core files and running processes. So when you type
anim nnn
the animator will first check to see if 'nnn' is number and, if so, see if it can dynamically attach to a process with that pid. Next, it will search for exes, down $PATH. It that fails, it will search using the standard RTS rules (using $COBPATH and the program_search_order tunable, etc). Finally, it checks to see if it's been asked to debug a core file.
In this case, as a script is an executable, it was be picked up first.
The ideal solution is not to have scripts with the same name as a program (a fairly obvious thing to avoid for lots of reasons). The other workaround is to 'anim ggg.so' (or equivalent), which will again avoid the problem.



