masqmail

diff src/alias.c @ 244:7082044c05c6

renamed `alias_local_cmp' to `localpartcmp' this is more accurate
author markus schnalke <meillo@marmaro.de>
date Mon, 25 Oct 2010 17:48:08 -0300
parents bc9d9cd9ee8e
children 273f6c9eb6a2
line diff
     1.1 --- a/src/alias.c	Mon Oct 25 17:46:13 2010 -0300
     1.2 +++ b/src/alias.c	Mon Oct 25 17:48:08 2010 -0300
     1.3 @@ -40,7 +40,7 @@
     1.4  			a = create_address_qualified(addr_node->data, TRUE, conf.host_name);
     1.5  			DEBUG(6) debugf("not_local_addresses: addr_node->data=%s a->address=%s\n",
     1.6  			                addr_node->data, a->address);
     1.7 -			if (addr_isequal(a, addr, conf.alias_local_cmp)) {
     1.8 +			if (addr_isequal(a, addr, conf.localpartcmp)) {
     1.9  				destroy_address(a);
    1.10  				/* in local_hosts but also in not_local_addresses */
    1.11  				return FALSE;
    1.12 @@ -54,7 +54,7 @@
    1.13  		a = create_address_qualified(addr_node->data, TRUE, conf.host_name);
    1.14  		DEBUG(6) debugf("local_addresses: addr_node->data=%s a->address=%s\n",
    1.15  		                addr_node->data, a->address);
    1.16 -		if (addr_isequal(a, addr, conf.alias_local_cmp)) {
    1.17 +		if (addr_isequal(a, addr, conf.localpartcmp)) {
    1.18  			destroy_address(a);
    1.19  			/* in local_addresses */
    1.20  			return TRUE;
    1.21 @@ -124,7 +124,7 @@
    1.22  		   see RFC 822 and RFC 5321 */
    1.23  		val = (gchar *) table_find_func(alias_table, addr->local_part, strcasecmp);
    1.24  	} else {
    1.25 -		val = (gchar *) table_find_func(alias_table, addr->local_part, conf.alias_local_cmp);
    1.26 +		val = (gchar *) table_find_func(alias_table, addr->local_part, conf.localpartcmp);
    1.27  	}
    1.28  	if (!val) {
    1.29  		DEBUG(5) debugf("alias: '%s' is fully expanded, hence completed\n",
    1.30 @@ -175,7 +175,7 @@
    1.31  
    1.32  		/* addr is local and to expand at this point */
    1.33  		/* but first ... search in parents for loops: */
    1.34 -		if (addr_isequal_parent(addr, alias_addr, conf.alias_local_cmp)) {
    1.35 +		if (addr_isequal_parent(addr, alias_addr, conf.localpartcmp)) {
    1.36  			/* loop detected, ignore this path */
    1.37  			logwrite(LOG_ALERT, "alias: detected loop, hence ignoring '%s'\n",
    1.38  			         alias_addr->local_part);
    1.39 @@ -238,7 +238,7 @@
    1.40  		rcpt_node_next = g_list_next(rcpt_node);
    1.41  		foreach(non_rcpt_list, non_node) {
    1.42  			address *non_addr = (address *) (non_node->data);
    1.43 -			if (addr_isequal(addr, non_addr, conf.alias_local_cmp)) {
    1.44 +			if (addr_isequal(addr, non_addr, conf.localpartcmp)) {
    1.45  				done_list = g_list_remove_link(done_list, rcpt_node);
    1.46  				g_list_free_1(rcpt_node);
    1.47  				/* this address is still in the children lists