/*
** Module   :BRANCH.SCR
** Abstract :Call external scripts for different messages
**
** Copyright (C) 1999, 2000  Link Guard Solutions Ltd.
**
** Log: Sun  01/10/2000 Updated
**
*/

/* List of message aliases */
alias.MSG_00000001="TIMER"
alias.MSG_00000003="CONNECT"
alias.MSG_00000004="DISCONNECT"
alias.MSG_000000F0="INIT"
alias.MSG_000000F1="DONE"

/* First process nonaliased handlers */

do i=1 to sf_get_config("branch.scr", arg(1), 0)
    interpret 'call "'sf_get_config("branch.scr", arg(1), i)'" arg(1), arg(2), arg(3), arg(4)'
end

/* Then check if alias is available and process aliased */

if symbol("ALIAS."||arg(1)) = 'VAR' then
do i=1 to sf_get_config("branch.scr", alias.arg(1), 0)
    interpret 'call "'sf_get_config("branch.scr", alias.arg(1), i)'" arg(1), arg(2), arg(3), arg(4)'
end

