-/* $Cambridge: exim/src/src/routers/queryprogram.c,v 1.3 2005/04/06 14:40:24 ph10 Exp $ */
+/* $Cambridge: exim/src/src/routers/queryprogram.c,v 1.6 2005/09/12 15:09:55 ph10 Exp $ */
/*************************************************
* Exim - an Internet mail transport agent *
router_instance *rblock, /* data for this instantiation */
address_item *addr, /* address we are working on */
struct passwd *pw, /* passwd entry after check_local_user */
- BOOL verify, /* TRUE when verifying */
+ int verify, /* v_none/v_recipient/v_sender/v_expn */
address_item **addr_local, /* add it to this if it's local */
address_item **addr_remote, /* add it to this if it's remote */
address_item **addr_new, /* put new addresses on here */
/* Nothing is written to the standard input. */
-close(fd_in);
+(void)close(fd_in);
/* Wait for the process to finish, applying the timeout, and inspect its return
code. */
/* Read the pipe to get the command's output, and then close it. */
len = read(fd_out, buffer, sizeof(buffer) - 1);
-close(fd_out);
+(void)close(fd_out);
/* Failure to return any data is an error. */
if (strcmpic(rword, US"decline") == 0) return DECLINE;
if (strcmpic(rword, US"pass") == 0) return PASS;
addr->message = string_copy(rdata); /* data is a message */
- if (strcmpic(rword, US"fail") == 0) return FAIL;
+ if (strcmpic(rword, US"fail") == 0)
+ {
+ setflag(addr, af_pass_message);
+ return FAIL;
+ }
if (strcmpic(rword, US"freeze") == 0) addr->special_action = SPECIAL_FREEZE;
else if (strcmpic(rword, US"defer") != 0)
{