#include "squid.h"
#include "comm.h"
#include "comm/Connection.h"
#include "fatal.h"
#include "fd.h"
#include "fs_io.h"
#include "log/File.h"
#include "log/ModUdp.h"
#include "Parsing.h"
#include "SquidConfig.h"
#include <cerrno>
Go to the source code of this file.
Classes | |
struct | l_udp_t |
Functions | |
static void | logfile_mod_udp_write (Logfile *lf, const char *buf, size_t len) |
static void | logfile_mod_udp_flush (Logfile *lf) |
static void | logfile_mod_udp_writeline (Logfile *lf, const char *buf, size_t len) |
static void | logfile_mod_udp_linestart (Logfile *) |
static void | logfile_mod_udp_lineend (Logfile *lf) |
static void | logfile_mod_udp_rotate (Logfile *, const int16_t) |
static void | logfile_mod_udp_close (Logfile *lf) |
int | logfile_mod_udp_open (Logfile *lf, const char *path, size_t bufsz, int fatal_flag) |
Function Documentation
◆ logfile_mod_udp_close()
|
static |
Definition at line 116 of file ModUdp.cc.
References l_udp_t::buf, Logfile::data, Logfile::f_flush, l_udp_t::fd, file_close(), and xfree.
Referenced by logfile_mod_udp_open().
◆ logfile_mod_udp_flush()
|
static |
Definition at line 61 of file ModUdp.cc.
References l_udp_t::buf, Logfile::data, logfile_mod_udp_write(), and l_udp_t::offset.
Referenced by logfile_mod_udp_open(), and logfile_mod_udp_writeline().
◆ logfile_mod_udp_lineend()
|
static |
Definition at line 104 of file ModUdp.cc.
References SquidConfig::buffered_logs, Config, Logfile::f_flush, and SquidConfig::onoff.
Referenced by logfile_mod_udp_open().
◆ logfile_mod_udp_linestart()
|
static |
Definition at line 99 of file ModUdp.cc.
Referenced by logfile_mod_udp_open().
◆ logfile_mod_udp_open()
Definition at line 135 of file ModUdp.cc.
References l_udp_t::buf, l_udp_t::bufsz, comm_connect_addr(), COMM_NONBLOCKING, comm_open(), Config, Logfile::data, DBG_IMPORTANT, debugs, SquidConfig::effectiveUser, Logfile::f_close, Logfile::f_flush, Logfile::f_lineend, Logfile::f_linestart, Logfile::f_linewrite, Logfile::f_rotate, FALSE, Logfile::fatal, fatalf(), l_udp_t::fd, Logfile::flags, GetHostWithPort(), Ip::Address::isIPv4(), logfile_mod_udp_close(), logfile_mod_udp_flush(), logfile_mod_udp_lineend(), logfile_mod_udp_linestart(), logfile_mod_udp_rotate(), logfile_mod_udp_writeline(), Logfile::path, safe_free, Ip::Address::setAnyAddr(), Ip::Address::setIPv4(), xcalloc(), xmalloc, xstrdup, and xstrerr().
Referenced by logfileOpen().
◆ logfile_mod_udp_rotate()
|
static |
Definition at line 111 of file ModUdp.cc.
Referenced by logfile_mod_udp_open().
◆ logfile_mod_udp_write()
Definition at line 40 of file ModUdp.cc.
References Logfile::data, DBG_IMPORTANT, debugs, l_udp_t::fd, fd_bytes(), FD_WRITE, and xstrerr().
Referenced by logfile_mod_udp_flush(), and logfile_mod_udp_writeline().
◆ logfile_mod_udp_writeline()
Definition at line 71 of file ModUdp.cc.
References assert, l_udp_t::buf, l_udp_t::bufsz, Logfile::data, logfile_mod_udp_flush(), logfile_mod_udp_write(), and l_udp_t::offset.
Referenced by logfile_mod_udp_open().