]> arthur.barton.de Git - ngircd.git/blobdiff - src/ngircd/ngircd.c
Don't #include client.h when conn.h/conn-func.h is already included
[ngircd.git] / src / ngircd / ngircd.c
index 5fc88c9c8c601293d5936df608c796c5423836ae..0319d8310766e07374af6737ce03ecc0ce03170f 100644 (file)
@@ -1,6 +1,6 @@
 /*
  * ngIRCd -- The Next Generation IRC Daemon
- * Copyright (c)2001-2009 Alexander Barton (alex@barton.de).
+ * Copyright (c)2001-2010 Alexander Barton (alex@barton.de).
  *
  * This program is free software; you can redistribute it and/or modify
  * it under the terms of the GNU General Public License as published by
 #endif
 
 #include "defines.h"
-#include "resolve.h"
 #include "conn.h"
 #include "conf-ssl.h"
-#include "client.h"
 #include "channel.h"
 #include "conf.h"
 #include "lists.h"
@@ -562,7 +560,7 @@ static void
 Show_Version( void )
 {
        puts( NGIRCd_Version );
-       puts( "Copyright (c)2001-2009 Alexander Barton (<alex@barton.de>) and Contributors." );
+       puts( "Copyright (c)2001-2010 Alexander Barton (<alex@barton.de>) and Contributors." );
        puts( "Homepage: <http://ngircd.barton.de/>\n" );
        puts( "This is free software; see the source for copying conditions. There is NO" );
        puts( "warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE." );
@@ -798,7 +796,9 @@ NGIRCd_Init( bool NGIRCd_NoDaemon )
 #else
                setpgrp(0, getpid());
 #endif
-               chdir( "/" );
+               if (chdir( "/" ) != 0)
+                       Log(LOG_ERR, "Can't change directory to '/': %s",
+                                    strerror(errno));
 
                /* Detach stdin, stdout and stderr */
                Setup_FDStreams( );