masqmail

diff src/listen.c @ 367:b27f66555ba8

Reformated multiline comments to have leading asterisks on each line Now we use: /* ** comment */ This makes the indent style simpler, too.
author markus schnalke <meillo@marmaro.de>
date Thu, 20 Oct 2011 10:20:59 +0200
parents 41958685480d
children 5781ba87df95
line diff
     1.1 --- a/src/listen.c	Thu Sep 22 15:07:40 2011 +0200
     1.2 +++ b/src/listen.c	Thu Oct 20 10:20:59 2011 +0200
     1.3 @@ -1,19 +1,20 @@
     1.4 -/*  MasqMail
     1.5 -    Copyright (C) 1999/2000 Oliver Kurth
     1.6 -
     1.7 -    This program is free software; you can redistribute it and/or modify
     1.8 -    it under the terms of the GNU General Public License as published by
     1.9 -    the Free Software Foundation; either version 2 of the License, or
    1.10 -    (at your option) any later version.
    1.11 -
    1.12 -    This program is distributed in the hope that it will be useful,
    1.13 -    but WITHOUT ANY WARRANTY; without even the implied warranty of
    1.14 -    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
    1.15 -    GNU General Public License for more details.
    1.16 -
    1.17 -    You should have received a copy of the GNU General Public License
    1.18 -    along with this program; if not, write to the Free Software
    1.19 -    Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
    1.20 +/*
    1.21 +**  MasqMail
    1.22 +**  Copyright (C) 1999/2000 Oliver Kurth
    1.23 +**
    1.24 +**  This program is free software; you can redistribute it and/or modify
    1.25 +**  it under the terms of the GNU General Public License as published by
    1.26 +**  the Free Software Foundation; either version 2 of the License, or
    1.27 +**  (at your option) any later version.
    1.28 +**
    1.29 +**  This program is distributed in the hope that it will be useful,
    1.30 +**  but WITHOUT ANY WARRANTY; without even the implied warranty of
    1.31 +**  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
    1.32 +**  GNU General Public License for more details.
    1.33 +**
    1.34 +**  You should have received a copy of the GNU General Public License
    1.35 +**  along with this program; if not, write to the Free Software
    1.36 +**  Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
    1.37  */
    1.38  
    1.39  #include <sys/wait.h>
    1.40 @@ -141,10 +142,12 @@
    1.41  
    1.42  	while (1) {
    1.43  
    1.44 -		/* if we were interrupted by an incoming connection (or a signal)
    1.45 -		   we have to recalculate the time until the next queue run should
    1.46 -		   occur. select may put a value into tm, but doc for select() says
    1.47 -		   we should not use it. */
    1.48 +		/*
    1.49 +		**  if we were interrupted by an incoming connection (or a
    1.50 +		**  signal) we have to recalculate the time until the next
    1.51 +		**  queue run should occur. select may put a value into tm,
    1.52 +		**  but doc for select() says we should not use it.
    1.53 +		*/
    1.54  		if (qival > 0) {
    1.55  			time(&time_now);
    1.56  			if (sel_ret == 0) {  /* we are either just starting or did a queue run */
    1.57 @@ -160,8 +163,11 @@
    1.58  					tm.tv_sec = 0;
    1.59  			}
    1.60  		}
    1.61 -		/* Block until input arrives on one or more active sockets,
    1.62 -		   or signal arrives, or queuing interval time elapsed (if qival > 0) */
    1.63 +		/*
    1.64 +		**  Block until input arrives on one or more active sockets,
    1.65 +		**  or signal arrives, or queuing interval time elapsed
    1.66 +		**  (if qival > 0)
    1.67 +		*/
    1.68  		read_fd_set = active_fd_set;
    1.69  		if ((sel_ret = select(FD_SETSIZE, &read_fd_set, NULL, NULL, qival > 0 ? &tm : NULL)) < 0) {
    1.70  			if (errno != EINTR) {
    1.71 @@ -194,8 +200,10 @@
    1.72  				}
    1.73  			}
    1.74  		} else {
    1.75 -			/* If select returns 0, the interval time has elapsed.
    1.76 -			   We start a new queue runner process */
    1.77 +			/*
    1.78 +			**  If select returns 0, the interval time has elapsed.
    1.79 +			**  We start a new queue runner process
    1.80 +			*/
    1.81  			int pid;
    1.82  			signal(SIGCHLD, sigchld_handler);
    1.83  			if ((pid = fork()) == 0) {