1 /* This is a test function for dynamic loading in Exim expansions. It uses the
2 number of arguments to control the result. */
4 /* These lines are taken from local_scan.h in the Exim source: */
6 /* ========================================================================== */
7 /* Return codes from the support functions lss_match_xxx(). These are also the
8 codes that dynamically-loaded ${dlfunc functions must return. */
10 #define OK 0 /* Successful match */
11 #define DEFER 1 /* Defer - some problem */
12 #define FAIL 2 /* Matching failed */
13 #define ERROR 3 /* Internal or config error */
15 /* Extra return code for ${dlfunc functions */
17 #define FAIL_FORCED 4 /* "Forced" failure */
18 /* ========================================================================== */
21 int dltest(unsigned char **yield, int argc, unsigned char *argv[])
33 *yield = (unsigned char *)"yield FAIL_FORCED";
37 *yield = (unsigned char *)"yield FAIL";