Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
View | Details | Raw Unified | Return to bug 418351 | Differences between
and this patch

Collapse All | Expand All

(-)a/doc/sqlite3.table (-3 / +6 lines)
Lines 1-9 Link Here
1
CREATE TABLE ulog (
1
CREATE TABLE IF NOT EXISTS ulog (
2
			raw_mac		VARCHAR(80),
2
			raw_mac		VARCHAR(80),
3
			oob_time_sec	INT UNSIGNED,
3
			oob_time_sec	INT UNSIGNED,
4
			oob_time_usec	INT UNSIGNED,
4
			oob_time_usec	INT UNSIGNED,
5
			ip_saddr	INT UNSIGNED,
5
			oob_prefix	VARCHAR(32),
6
			ip_daddr	INT UNSIGNED,
6
			oob_in		VARCHAR(32),
7
			oob_out		VARCHAR(32),
8
			ip_saddr	VARCHAR(16),
9
			ip_daddr	VARCHAR(16),
7
			ip_protocol	TINYINT UNSIGNED,
10
			ip_protocol	TINYINT UNSIGNED,
8
			ip_totlen       SMALLINT UNSIGNED,
11
			ip_totlen       SMALLINT UNSIGNED,
9
			tcp_sport	SMALLINT UNSIGNED,
12
			tcp_sport	SMALLINT UNSIGNED,
(-)a/sqlite3/ulogd_SQLITE3.c (-1 / +1 lines)
Lines 148-154 static int _sqlite3_output(ulog_iret_t *result) Link Here
148
				memset(&addr, 0, sizeof(addr));
148
				memset(&addr, 0, sizeof(addr));
149
				addr.s_addr = ntohl(res->value.ui32);
149
				addr.s_addr = ntohl(res->value.ui32);
150
				ipaddr = inet_ntoa(addr);
150
				ipaddr = inet_ntoa(addr);
151
				sqlite3_bind_text(p_stmt,col_counter,ipaddr,strlen(ipaddr),SQLITE_STATIC);
151
				sqlite3_bind_text(p_stmt,col_counter,ipaddr,strlen(ipaddr),SQLITE_TRANSIENT);
152
                                break;
152
                                break;
153
#endif /* IP_AS_STRING */
153
#endif /* IP_AS_STRING */
154
			/* EVIL: fallthrough when logging IP as u_int32_t */
154
			/* EVIL: fallthrough when logging IP as u_int32_t */

Return to bug 418351