masqmail-0.2
diff src/deliver.c @ 114:a80ebfa16cd5
better debugging output (thanks to Paolo)
author | meillo@marmaro.de |
---|---|
date | Wed, 30 Jun 2010 15:00:59 +0200 |
parents | 3b344bf57162 |
children | 349518b940db |
line diff
1.1 --- a/src/deliver.c Wed Jun 30 13:23:49 2010 +0200 1.2 +++ b/src/deliver.c Wed Jun 30 15:00:59 2010 +0200 1.3 @@ -693,8 +693,11 @@ 1.4 GList *localnet_rcpt_list = NULL; 1.5 GList *other_rcpt_list; 1.6 1.7 - if (!spool_lock(msgout->msg->uid)) 1.8 + if (!spool_lock(msgout->msg->uid)) { 1.9 + DEBUG(5) debugf("spool_lock(%s) failed.\n", msgout->msg->uid); 1.10 continue; 1.11 + } 1.12 + DEBUG(5) debugf("spool_lock(%s)\n", msgout->msg->uid); 1.13 1.14 rcpt_list = g_list_copy(msgout->msg->rcpt_list); 1.15 if (conf.log_user) { 1.16 @@ -751,6 +754,7 @@ 1.17 1.18 /* actual delivery */ 1.19 if (local_msgout_list != NULL) { 1.20 + DEBUG(5) debugf("local_msgout_list\n"); 1.21 foreach(local_msgout_list, msgout_node) { 1.22 msg_out *msgout = (msg_out *) (msgout_node->data); 1.23 if (!deliver_local(msgout)) 1.24 @@ -763,6 +767,7 @@ 1.25 GList *route_list = NULL; 1.26 GList *route_node; 1.27 1.28 + DEBUG(5) debugf("localnet_msgout_list\n"); 1.29 if (conf.local_net_routes) 1.30 route_list = read_route_list(conf.local_net_routes, TRUE); 1.31 else 1.32 @@ -778,6 +783,7 @@ 1.33 } 1.34 1.35 if (other_msgout_list != NULL) { 1.36 + DEBUG(5) debugf("other_msgout_list\n"); 1.37 if (!deliver_msgout_list_online(other_msgout_list)) 1.38 ok = FALSE; 1.39 destroy_msg_out_list(other_msgout_list); 1.40 @@ -785,7 +791,12 @@ 1.41 1.42 foreach(msgout_list, msgout_node) { 1.43 msg_out *msgout = (msg_out *) (msgout_node->data); 1.44 - spool_unlock(msgout->msg->uid); 1.45 + if (spool_unlock(msgout->msg->uid)) { 1.46 + DEBUG(5) debugf("spool_unlock(%s)\n", msgout->msg->uid); 1.47 + } else { 1.48 + DEBUG(5) debugf("spool_unlock(%s) failed.\n", msgout->msg->uid); 1.49 + } 1.50 + 1.51 } 1.52 1.53 destroy_msg_out_list(msgout_list);