2 ** ext_hook.c -- Run a program that hooks into some other system.
8 ** The filename arguments are given full path names.
9 ** msg_filename2 might contain a NULL pointer if not needed.
10 ** Look in the context for an error message if something goes wrong;
11 ** there is a built-in message in case one isn't specified.
12 ** Only produces the error message once.
15 ext_hook(char *hook_name, char *msg_filename1, char *msg_filename2)
17 char *hook; /* hook program from context */
20 static int did_message = 0; /* we've already output a message */
22 if (!(hook = context_find(hook_name))) {
25 status = execprogl(mhbasename(hook), mhbasename(hook),
26 msg_filename1, msg_filename2,
32 advise(NULL, "external hook (%s) failed.", hook);