tcpflow
1.6.1
About: tcpflow is a TCP/IP packet demultiplexer that captures data transmitted as part of TCP connections (flows), and stores the data in a way that is convenient for protocol analysis and debugging.
![]() ![]() |
#include "config.h"
#include "cppmutex.h"
#include "utils.h"
#include <stdio.h>
#include <errno.h>
#include <fcntl.h>
#include <ctype.h>
#include <assert.h>
#include <inttypes.h>
#include <stdlib.h>
#include <sys/stat.h>
#include <string.h>
#include <stdarg.h>
#include <sstream>
Go to the source code of this file.
Macros | |
#define | _FILE_OFFSET_BITS 64 |
#define | __STDC_FORMAT_MACROS |
Functions | |
void | err (int eval, const char *fmt,...) |
void | errx (int eval, const char *fmt,...) |
void | warn (const char *fmt,...) |
void | warnx (const char *fmt,...) |
void | localtime_r (time_t *t, struct tm *tm) |
void | gmtime_r (time_t *t, struct tm *tm) |
bool | ends_with (const std::string &buf, const std::string &with) |
bool | ends_with (const std::wstring &buf, const std::wstring &with) |
std::vector< std::string > & | split (const std::string &s, char delim, std::vector< std::string > &elems) |
std::vector< std::string > | split (const std::string &s, char delim) |
Variables | |
cppmutex | localtime_mutex |
cppmutex | gmtime_mutex |
#define _FILE_OFFSET_BITS 64 |
bool ends_with | ( | const std::string & | buf, |
const std::string & | with | ||
) |
bool ends_with | ( | const std::wstring & | buf, |
const std::wstring & | with | ||
) |
void err | ( | int | eval, |
const char * | fmt, | ||
... | |||
) |
Definition at line 33 of file utils.cpp.
Referenced by http_errno_description(), http_errno_name(), main(), and utf8::internal::validate_next().
void gmtime_r | ( | time_t * | t, |
struct tm * | tm | ||
) |
Definition at line 98 of file utils.cpp.
References gmtime_mutex.
Referenced by microsoftDateToISODate(), and unixTimeToISODate().
void localtime_r | ( | time_t * | t, |
struct tm * | tm | ||
) |
Definition at line 88 of file utils.cpp.
References localtime_mutex.
std::vector< std::string > split | ( | const std::string & | s, |
char | delim | ||
) |
std::vector< std::string > & split | ( | const std::string & | s, |
char | delim, | ||
std::vector< std::string > & | elems | ||
) |
Definition at line 133 of file utils.cpp.
Referenced by main(), mkdirs_for_path(), and split().
cppmutex gmtime_mutex |
Definition at line 97 of file utils.cpp.
Referenced by gmtime_r().
cppmutex localtime_mutex |
Extract a buffer...
buf | - the buffer to extract; |
buflen | - the size of the page to extract |
pos0 | - the byte position of buf[0] |
Definition at line 87 of file utils.cpp.
Referenced by localtime_r().