/* * Copyright (c) 2022 * by AVM GmbH Berlin, Germany * * Licence: Free, use with no restriction. * * vim: expandtab fileencoding=utf-8 shiftwidth=4 softtabstop=4 */ #ifdef HAVE_CONFIG_H #include "config.h" #endif #ifdef TIME_WITH_SYS_TIME # include # include #else # ifdef HAVE_SYS_TIME_H # include # else # include # endif #endif #include #include #include #include #include "clog2file.h" #include "ftplog.h" static const char *log_base_path = "/var/tmp/ftpd/"; /* Base path for logging */ static char *create_filename(const int pid_ftpd) { static char buf[32]; snprintf(buf, sizeof(buf), "%sftpd.%d.log", log_base_path, pid_ftpd); return buf; } //########################################################################### void ftplog_msg(const char *format, ...) { va_list args; va_start(args, format); clog2file_vxmsg(create_filename(getpid()), "ftpd", format, args); va_end(args); } //###########################################################################