/*
- * Run a program that hooks into some other system. The first argument is
- * name of the hook to use, the second is the full path name of a mail message.
- * The third argument is also the full path name of a mail message, or a NULL
- * pointer if it isn't needed. Look in the context for an error message if
- * something goes wrong; there is a built-in message in case one isn't specified.
- * Only produce the error message once.
- */
+** Run a program that hooks into some other system. The first argument is
+** name of the hook to use, the second is the full path name of a mail message.
+** The third argument is also the full path name of a mail message, or a NULL
+** pointer if it isn't needed. Look in the context for an error message if
+** something goes wrong; there is a built-in message in case one isn't
+** specified. Only produce the error message once.
+*/
#include <h/mh.h>
break;
case 0:
- vec[0] = r1bindex(hook, '/');
+ vec[0] = mhbasename(hook);
vec[1] = message_file_name_1;
vec[2] = message_file_name_2;
vec[3] = (char *)0;
}
return (NOTOK);
- }
-
- else
+ } else
return (OK);
}