masqmail-0.2

diff src/mservdetect.c @ 10:26e34ae9a3e3

changed indention and line wrapping to a more consistent style
author meillo@marmaro.de
date Mon, 27 Oct 2008 16:23:10 +0100
parents 08114f7dcc23
children
line diff
     1.1 --- a/src/mservdetect.c	Mon Oct 27 16:21:27 2008 +0100
     1.2 +++ b/src/mservdetect.c	Mon Oct 27 16:23:10 2008 +0100
     1.3 @@ -32,45 +32,47 @@
     1.4  #include "masqmail.h"
     1.5  #include "readsock.h"
     1.6  #include "mserver.h"
     1.7 -#endif /* ENABLE_MSERVER */
     1.8 +#endif  /* ENABLE_MSERVER */
     1.9  
    1.10 -void logwrite(int pri, const char *fmt, ...)
    1.11 +void
    1.12 +logwrite(int pri, const char *fmt, ...)
    1.13  {
    1.14 -  va_list args;
    1.15 -  va_start(args, fmt);
    1.16 +	va_list args;
    1.17 +	va_start(args, fmt);
    1.18  
    1.19 -  vfprintf(stdout, fmt, args);
    1.20 +	vfprintf(stdout, fmt, args);
    1.21  
    1.22 -  va_end(args);
    1.23 +	va_end(args);
    1.24  }
    1.25  
    1.26 -void debugf(const char *fmt, ...)
    1.27 +void
    1.28 +debugf(const char *fmt, ...)
    1.29  {
    1.30 -  va_list args;
    1.31 -  va_start(args, fmt);
    1.32 +	va_list args;
    1.33 +	va_start(args, fmt);
    1.34  
    1.35 -  vfprintf(stdout, fmt, args);
    1.36 +	vfprintf(stdout, fmt, args);
    1.37  
    1.38 -  va_end(args);
    1.39 +	va_end(args);
    1.40  }
    1.41  
    1.42 -int main(int argc, char *argv[])
    1.43 +int
    1.44 +main(int argc, char *argv[])
    1.45  {
    1.46 -  if(argc == 3){
    1.47 -    interface iface;
    1.48 -    gchar *name;
    1.49 +	if (argc == 3) {
    1.50 +		interface iface;
    1.51 +		gchar *name;
    1.52  
    1.53 -    iface.address = g_strdup(argv[1]);
    1.54 -    iface.port = atoi(argv[2]);
    1.55 +		iface.address = g_strdup(argv[1]);
    1.56 +		iface.port = atoi(argv[2]);
    1.57  
    1.58 -    name = mserver_detect_online(&iface);
    1.59 +		name = mserver_detect_online(&iface);
    1.60  
    1.61 -    printf("%s\n", name);
    1.62 +		printf("%s\n", name);
    1.63  
    1.64 -    exit(EXIT_SUCCESS);
    1.65 -  }else{
    1.66 -    fprintf(stderr, "usage %s <host> <port>\n", argv[0]);
    1.67 -    exit(EXIT_FAILURE);
    1.68 -  }
    1.69 +		exit(EXIT_SUCCESS);
    1.70 +	} else {
    1.71 +		fprintf(stderr, "usage %s <host> <port>\n", argv[0]);
    1.72 +		exit(EXIT_FAILURE);
    1.73 +	}
    1.74  }
    1.75 -