masqmail

diff src/masqmail.c @ 258:05fa719b7002

fixed -oem by removing it ;-) The implemenation of -oem had been very weird. docs/oem-option explains the situation and the fix.
author markus schnalke <meillo@marmaro.de>
date Wed, 01 Dec 2010 18:27:46 -0300
parents 8cca5305e4f0
children f4117fd5a163
line diff
     1.1 --- a/src/masqmail.c	Wed Dec 01 17:29:52 2010 -0300
     1.2 +++ b/src/masqmail.c	Wed Dec 01 18:27:46 2010 -0300
     1.3 @@ -391,7 +391,6 @@
     1.4  	gchar *M_cmd = NULL;
     1.5  	gboolean opt_t = FALSE;
     1.6  	gboolean opt_i = FALSE;
     1.7 -	gboolean exit_failure = FALSE;
     1.8  	gint exit_code = EXIT_SUCCESS;
     1.9  	gchar *conf_file = CONF_FILE;
    1.10  	gchar *route_name = NULL;
    1.11 @@ -488,7 +487,6 @@
    1.12  
    1.13  		} else if (strcmp(opt, "i") == 0) {
    1.14  			opt_i = TRUE;
    1.15 -			exit_failure = FALSE;  /* may override -oem */
    1.16  
    1.17  		} else if (strcmp(opt, "m") == 0) {
    1.18  			/* ignore -m (me too) switch (see man page) */
    1.19 @@ -500,15 +498,8 @@
    1.20  		} else if (strcmp(opt, "odq") == 0) {
    1.21  			do_queue = TRUE;
    1.22  
    1.23 -		} else if (strcmp(opt, "oem") == 0) {
    1.24 -			if (!opt_i) {
    1.25 -				/* TODO: Why is this related to -i in any way? */
    1.26 -				exit_failure = TRUE;
    1.27 -			}
    1.28 -
    1.29  		} else if (strcmp(opt, "oi") == 0) {
    1.30  			opt_i = TRUE;
    1.31 -			exit_failure = FALSE;  /* may override -oem */
    1.32  
    1.33  		} else if (strncmp(opt, "o", 1) == 0) {
    1.34  			/* ignore all other -oXXX options */
    1.35 @@ -693,7 +684,7 @@
    1.36  			guint accept_flags = (opt_t ? ACC_DEL_RCPTS | ACC_RCPT_FROM_HEAD : 0)
    1.37  			                     | (opt_i ? ACC_DOT_IGNORE : ACC_NODOT_RELAX);
    1.38  			mode_accept(return_path, full_sender_name, accept_flags, &(argv[arg]), argc - arg);
    1.39 -			exit(exit_failure ? EXIT_FAILURE : EXIT_SUCCESS);
    1.40 +			exit(0);
    1.41  		}
    1.42  		break;
    1.43  	case MODE_NONE: