]> jfr.im git - irc/rqf/shadowircd.git/blobdiff - src/s_log.c
ok, trying to work on blockheap's stuff
[irc/rqf/shadowircd.git] / src / s_log.c
index 129d2241169859b19cb16777e338bdb64e3c875a..de696d3e03fecb7f73eefda2df7202ca843b98c7 100644 (file)
@@ -28,7 +28,7 @@
  * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
  * POSSIBILITY OF SUCH DAMAGE.
  *
- * $Id: s_log.c 1563 2006-06-02 00:43:35Z nenolod $
+ * $Id: s_log.c 3209 2007-02-11 16:54:43Z jilles $
  */
 
 #include "stdinc.h"
@@ -77,7 +77,7 @@ void
 init_main_logfile(void)
 {
        if(log_main == NULL)
-               log_main = fopen(LPATH, "a");
+               log_main = fopen(logFileName, "a");
 }
 
 void
@@ -88,7 +88,7 @@ open_logfiles(void)
        if(log_main != NULL)
                fclose(log_main);
 
-       log_main = fopen(LPATH, "a");
+       log_main = fopen(logFileName, "a");
 
        /* log_main is handled above, so just do the rest */
        for(i = 1; i < LAST_LOGFILE; i++)
@@ -121,7 +121,7 @@ ilog(ilogfile dest, const char *format, ...)
        ircvsnprintf(buf, sizeof(buf), format, args);
        va_end(args);
 
-       ircsnprintf(buf2, sizeof(buf2), "%s %s\n", smalldate(), buf);
+       rb_snprintf(buf2, sizeof(buf2), "%s %s\n", smalldate(), buf);
 
        if(fputs(buf2, logfile) < 0)
        {
@@ -210,11 +210,11 @@ smalldate(void)
 {
        static char buf[MAX_DATE_STRING];
        struct tm *lt;
-       time_t ltime = CurrentTime;
+       time_t ltime = rb_current_time();
 
        lt = localtime(&ltime);
 
-       ircsnprintf(buf, sizeof(buf), "%d/%d/%d %02d.%02d",
+       rb_snprintf(buf, sizeof(buf), "%d/%d/%d %02d.%02d",
                    lt->tm_year + 1900, lt->tm_mon + 1,
                    lt->tm_mday, lt->tm_hour, lt->tm_min);