input stringlengths 16 454k | output stringlengths 13 350k | function_name stringlengths 1 100 | repo_name stringlengths 6 43 | category stringclasses 76
values | sample_id stringlengths 22 88 | decompiler stringclasses 1
value | opt_level stringclasses 1
value |
|---|---|---|---|---|---|---|---|
int build_nfct_filter_proto(nfct_filter *filter, char *filter_string) {
struct protoent *pent;
struct protoent *penta;
char *comma;
while (1) {
comma = strchr(filter_string, 44);
if (!comma)
break;
*comma = 0;
pent = getprotobyname(filter_string);
if (!pent) {
__ulogd_log(8, "ul... | static int build_nfct_filter_proto(struct nfct_filter *filter,
char *filter_string) {
char *from = filter_string;
char *comma;
struct protoent *pent = NULL;
while ((comma = strchr(from, ',')) != NULL) {
size_t len = comma - from;
*comma = 0;
pent = getprotobyname(... | build_nfct_filter_proto | ulogd-2.0.7-r3 | app-admin | O0/app-admin/ulogd-2.0.7-r3/ulogd_inpflow_NFCT.so | ida | O0 |
int compare(const void *data1, const void *data2) {
long v2;
long v3;
return nfct_cmp(*((_QWORD *)data1 + 6), data2, 3, data2, v2, v3, data2, data1,
data1, data2);
} | static int compare(const void *data1, const void *data2) {
const struct ct_timestamp *u1 = data1;
const struct nf_conntrack *ct = data2;
return nfct_cmp(u1->ct, ct, NFCT_CMP_ORIG | NFCT_CMP_REPL);
} | compare | ulogd-2.0.7-r3 | app-admin | O0/app-admin/ulogd-2.0.7-r3/ulogd_inpflow_NFCT.so | ida | O0 |
int configure_nfct(ulogd_pluginstance *upi, ulogd_pluginstance_stack *stack) {
int ret;
ret = config_parse_file(upi->id, upi->config_kset);
if (ret >= 0)
return 0;
else
return ret;
} | static int configure_nfct(struct ulogd_pluginstance *upi,
struct ulogd_pluginstance_stack *stack) {
int ret;
ret = config_parse_file(upi->id, upi->config_kset);
if (ret < 0)
return ret;
return 0;
} | configure_nfct | ulogd-2.0.7-r3 | app-admin | O0/app-admin/ulogd-2.0.7-r3/ulogd_inpflow_NFCT.so | ida | O0 |
int constructor_nfct(ulogd_pluginstance *upi) {
if (upi->config_kset->ces[0].u.value)
return constructor_nfct_polling(upi);
else
return constructor_nfct_events(upi);
} | static int constructor_nfct(struct ulogd_pluginstance *upi) {
if (pollint_ce(upi->config_kset).u.value == 0) {
return constructor_nfct_events(upi);
} else {
return constructor_nfct_polling(upi);
}
ulogd_log(ULOGD_FATAL, "invalid NFCT configuration\n");
return -1;
} | constructor_nfct | ulogd-2.0.7-r3 | app-admin | O0/app-admin/ulogd-2.0.7-r3/ulogd_inpflow_NFCT.so | ida | O0 |
int constructor_nfct_events(ulogd_pluginstance *upi) {
int v1;
int v2;
int v3;
hashtable *v4;
int v5;
int family;
nfct_pluginstance *cpi;
nfct_handle *h;
unsigned long v10;
v10 = __readfsqword(0x28u);
cpi = (nfct_pluginstance *)upi->private;
*(_QWORD *)upi->private =
nfct_open(1, (unsigne... | static int constructor_nfct_events(struct ulogd_pluginstance *upi) {
struct nfct_pluginstance *cpi = (struct nfct_pluginstance *)upi->private;
cpi->cth =
nfct_open(NFNL_SUBSYS_CTNETLINK, eventmask_ce(upi->config_kset).u.value);
if (!cpi->cth) {
ulogd_log(ULOGD_FATAL, "error opening ctnetlink\n");
g... | constructor_nfct_events | ulogd-2.0.7-r3 | app-admin | O0/app-admin/ulogd-2.0.7-r3/ulogd_inpflow_NFCT.so | ida | O0 |
int constructor_nfct_polling(ulogd_pluginstance *upi) {
if (!upi->config_kset->ces[1].u.value) {
__ulogd_log(8, "ulogd_inpflow_NFCT.c", 1422,
"NFCT polling mode requires the hashtable\n");
return -1;
}
*(_QWORD *)&upi->private[16] = nfct_open(1, 0);
if (!*(_QWORD *)&upi->private[16]) {
... | static int constructor_nfct_polling(struct ulogd_pluginstance *upi) {
struct nfct_pluginstance *cpi = (struct nfct_pluginstance *)upi->private;
if (usehash_ce(upi->config_kset).u.value == 0) {
ulogd_log(ULOGD_FATAL, "NFCT polling mode requires "
"the hashtable\n");
goto err;
}
... | constructor_nfct_polling | ulogd-2.0.7-r3 | app-admin | O0/app-admin/ulogd-2.0.7-r3/ulogd_inpflow_NFCT.so | ida | O0 |
int destructor_nfct(ulogd_pluginstance *upi) {
if (upi->config_kset->ces[0].u.value)
return destructor_nfct_polling(upi);
else
return destructor_nfct_events(upi);
} | static int destructor_nfct(struct ulogd_pluginstance *upi) {
if (pollint_ce(upi->config_kset).u.value == 0) {
return destructor_nfct_events(upi);
} else {
return destructor_nfct_polling(upi);
}
ulogd_log(ULOGD_FATAL, "invalid NFCT configuration\n");
return -1;
} | destructor_nfct | ulogd-2.0.7-r3 | app-admin | O0/app-admin/ulogd-2.0.7-r3/ulogd_inpflow_NFCT.so | ida | O0 |
int destructor_nfct_events(ulogd_pluginstance *upi) {
int rc;
int rca;
int rcb;
ulogd_unregister_fd(&upi->private[24]);
rc = nfct_close(*(_QWORD *)upi->private);
if (rc < 0)
return rc;
nfct_destroy(*(_QWORD *)&upi->private[264]);
if (upi->config_kset->ces[1].u.value) {
ulogd_del_timer(&upi->pri... | static int destructor_nfct_events(struct ulogd_pluginstance *upi) {
struct nfct_pluginstance *cpi = (void *)upi->private;
int rc;
ulogd_unregister_fd(&cpi->nfct_fd);
rc = nfct_close(cpi->cth);
if (rc < 0)
return rc;
nfct_destroy(cpi->ct);
if (usehash_ce(upi->config_kset).u.value != 0) {
ulogd_... | destructor_nfct_events | ulogd-2.0.7-r3 | app-admin | O0/app-admin/ulogd-2.0.7-r3/ulogd_inpflow_NFCT.so | ida | O0 |
int destructor_nfct_polling(ulogd_pluginstance *upi) {
int rc;
rc = nfct_close(*(_QWORD *)&upi->private[16]);
if (rc >= 0)
return 0;
else
return rc;
} | static int destructor_nfct_polling(struct ulogd_pluginstance *upi) {
int rc;
struct nfct_pluginstance *cpi = (void *)upi->private;
rc = nfct_close(cpi->pgh);
if (rc < 0)
return rc;
return 0;
} | destructor_nfct_polling | ulogd-2.0.7-r3 | app-admin | O0/app-admin/ulogd-2.0.7-r3/ulogd_inpflow_NFCT.so | ida | O0 |
int do_free(void *data1, void *data2) {
nfct_destroy(*((_QWORD *)data2 + 6));
free(data2);
return 0;
} | static int do_free(void *data1, void *data2) {
struct ct_timestamp *ts = data2;
nfct_destroy(ts->ct);
free(ts);
return 0;
} | do_free | ulogd-2.0.7-r3 | app-admin | O0/app-admin/ulogd-2.0.7-r3/ulogd_inpflow_NFCT.so | ida | O0 |
void do_propagate_ct(ulogd_pluginstance *upi, nf_conntrack *ct, int type,
ct_timestamp *ts) {
ulogd_pluginstance *npi;
llist_head *__mptr;
const llist_head *__mptr_0;
nfct_copy(*(_QWORD *)&upi->private[264], ct, 8);
__mptr = upi->plist.next;
npi = (ulogd_pluginstance *)&__mptr[-1];
p... | static void do_propagate_ct(struct ulogd_pluginstance *upi,
struct nf_conntrack *ct, int type,
struct ct_timestamp *ts) {
struct ulogd_pluginstance *npi = NULL;
struct nfct_pluginstance *cpi = (struct nfct_pluginstance *)upi->private;
nfct_copy(cpi->ct, ct,... | do_propagate_ct | ulogd-2.0.7-r3 | app-admin | O0/app-admin/ulogd-2.0.7-r3/ulogd_inpflow_NFCT.so | ida | O0 |
int do_purge(void *data1, void *data2) {
if ((unsigned int)nfct_query(*((_QWORD *)data1 + 17), 3,
*((_QWORD *)data2 + 6)) == -1 &&
*__errno_location() == 2) {
do_propagate_ct((ulogd_pluginstance *)data1, *((nf_conntrack **)data2 + 6),
4, (ct_timestamp *)dat... | static int do_purge(void *data1, void *data2) {
int ret;
struct ulogd_pluginstance *upi = data1;
struct ct_timestamp *ts = data2;
struct nfct_pluginstance *cpi = (struct nfct_pluginstance *)upi->private;
ret = nfct_query(cpi->pgh, NFCT_Q_GET, ts->ct);
if (ret == -1 && errno == ENOENT) {
do_propagate_ct... | do_purge | ulogd-2.0.7-r3 | app-admin | O0/app-admin/ulogd-2.0.7-r3/ulogd_inpflow_NFCT.so | ida | O0 |
int dump_reset_handler(nf_conntrack_msg_type type, nf_conntrack *ct,
void *data) {
int ret;
unsigned int id;
ct_timestamp *ts;
nfct_pluginstance *cpi;
cpi = (nfct_pluginstance *)((char *)data + 120);
ret = 1;
if (type == nf_conntrack_msg_type_NFCT_T_UPDATE) {
id = hashtable_has... | static int dump_reset_handler(enum nf_conntrack_msg_type type,
struct nf_conntrack *ct, void *data) {
struct ulogd_pluginstance *upi = data;
struct nfct_pluginstance *cpi = (struct nfct_pluginstance *)upi->private;
int ret = NFCT_CB_CONTINUE, rc, id;
struct ct_timestamp *ts;
swi... | dump_reset_handler | ulogd-2.0.7-r3 | app-admin | O0/app-admin/ulogd-2.0.7-r3/ulogd_inpflow_NFCT.so | ida | O0 |
int event_handler_hashtable(nf_conntrack_msg_type type, nf_conntrack *ct,
void *data) {
unsigned int ida;
unsigned int id;
unsigned int idb;
nfct_pluginstance *cpi;
ct_timestamp *ts;
ct_timestamp *tsa;
ct_timestamp *tsb;
ct_timestamp tmp;
unsigned long v13;
v13 = __readf... | static int event_handler_hashtable(enum nf_conntrack_msg_type type,
struct nf_conntrack *ct, void *data) {
struct ulogd_pluginstance *upi = data;
struct nfct_pluginstance *cpi = (struct nfct_pluginstance *)upi->private;
struct ct_timestamp *ts;
int ret, id;
switch (type) {
... | event_handler_hashtable | ulogd-2.0.7-r3 | app-admin | O0/app-admin/ulogd-2.0.7-r3/ulogd_inpflow_NFCT.so | ida | O0 |
int event_handler_no_hashtable(nf_conntrack_msg_type type, nf_conntrack *ct,
void *data) {
ct_timestamp tmp;
unsigned long v6;
v6 = __readfsqword(0x28u);
memset(&tmp, 0, 48);
tmp.ct = ct;
if (type == nf_conntrack_msg_type_NFCT_T_NEW) {
set_timestamp_from_ct(&tmp, ct, 0);
... | static int event_handler_no_hashtable(enum nf_conntrack_msg_type type,
struct nf_conntrack *ct, void *data) {
struct ulogd_pluginstance *upi = data;
struct ct_timestamp tmp = {
.ct = ct,
};
switch (type) {
case NFCT_T_NEW:
set_timestamp_from_ct(&tmp, ct, START)... | event_handler_no_hashtable | ulogd-2.0.7-r3 | app-admin | O0/app-admin/ulogd-2.0.7-r3/ulogd_inpflow_NFCT.so | ida | O0 |
void get_ctr_zero(ulogd_pluginstance *upi) {
int family;
nfct_handle *h;
unsigned long v3;
v3 = __readfsqword(0x28u);
family = 0;
h = (nfct_handle *)nfct_open(1, 0);
if (h) {
nfct_callback_register(h, 7, dump_reset_handler, upi);
if ((unsigned int)nfct_query(h, 6, &family) == -1)
__ulogd_lo... | static void get_ctr_zero(struct ulogd_pluginstance *upi) {
struct nfct_handle *h;
int family = AF_UNSPEC;
h = nfct_open(CONNTRACK, 0);
if (h == NULL) {
ulogd_log(ULOGD_FATAL, "Cannot dump and reset counters\n");
return;
}
nfct_callback_register(h, NFCT_T_ALL, &dump_reset_handler, upi);
if (nfct_q... | get_ctr_zero | ulogd-2.0.7-r3 | app-admin | O0/app-admin/ulogd-2.0.7-r3/ulogd_inpflow_NFCT.so | ida | O0 |
uint32_t hash(const void *data, const hashtable *table) {
char attr_u8;
uint32_t ret;
ret = 0;
attr_u8 = nfct_get_attr_u8(data, 15);
if (attr_u8 == 2)
return _hash4((const nf_conntrack *)data, table);
if (attr_u8 == 10)
return _hash6((const nf_conntrack *)data, table);
return ret;
} | static uint32_t hash(const void *data, const struct hashtable *table) {
int ret = 0;
const struct nf_conntrack *ct = data;
switch (nfct_get_attr_u8(ct, ATTR_L3PROTO)) {
case AF_INET:
ret = __hash4(ct, table);
break;
case AF_INET6:
ret = __hash6(ct, table);
break;
default:
break;
}
... | hash | ulogd-2.0.7-r3 | app-admin | O0/app-admin/ulogd-2.0.7-r3/ulogd_inpflow_NFCT.so | ida | O0 |
void init() { ulogd_register_plugin(&nfct_plugin); } | void init(void) { ulogd_register_plugin(&nfct_plugin); } | init | ulogd-2.0.7-r3 | app-admin | O0/app-admin/ulogd-2.0.7-r3/ulogd_inpflow_NFCT.so | ida | O0 |
int nfct_add_to_filter(nfct_filter *filter, ulogd_addr *addr, int l3, int dir) {
int filter_dir_ipv4;
int filter_dir_ipv6;
nfct_filter_ipv4 filter_ipv4;
nfct_filter_ipv6 filter_ipv6;
unsigned long v10;
v10 = __readfsqword(0x28u);
if (nfct_set_dir(dir, &filter_dir_ipv4, &filter_dir_ipv6) == -1)
return... | static int nfct_add_to_filter(struct nfct_filter *filter,
struct ulogd_addr *addr, int l3, int dir) {
int filter_dir_ipv4;
int filter_dir_ipv6;
if (nfct_set_dir(dir, &filter_dir_ipv4, &filter_dir_ipv6) == -1)
return -1;
switch (l3) {
case AF_INET6: {
struct nfct_filter_... | nfct_add_to_filter | ulogd-2.0.7-r3 | app-admin | O0/app-admin/ulogd-2.0.7-r3/ulogd_inpflow_NFCT.so | ida | O0 |
int nfct_set_dir(int dir, int *filter_dir_ipv4, int *filter_dir_ipv6) {
if (dir == 1) {
*filter_dir_ipv4 = 2;
*filter_dir_ipv6 = 4;
} else {
if (dir != 2) {
__ulogd_log(8, "ulogd_inpflow_NFCT.c", 1064, "Invalid direction %d\n",
dir);
return -1;
}
*filter_dir_ipv4 = ... | static inline int nfct_set_dir(int dir, int *filter_dir_ipv4,
int *filter_dir_ipv6) {
switch (dir) {
case NFCT_DST_DIR:
*filter_dir_ipv4 = NFCT_FILTER_DST_IPV4;
*filter_dir_ipv6 = NFCT_FILTER_DST_IPV6;
break;
case NFCT_SRC_DIR:
*filter_dir_ipv4 = NFCT_FILTER_SRC_IPV4... | nfct_set_dir | ulogd-2.0.7-r3 | app-admin | O0/app-admin/ulogd-2.0.7-r3/ulogd_inpflow_NFCT.so | ida | O0 |
int overrun_handler(nf_conntrack_msg_type type, nf_conntrack *ct, void *data) {
unsigned int id;
nfct_pluginstance *cpi;
ct_timestamp *ts;
cpi = (nfct_pluginstance *)((char *)data + 120);
id = hashtable_hash(*((_QWORD *)data + 46), ct);
if (hashtable_find(cpi->ct_active, ct, id))
return 1;
ts = (ct_t... | static int overrun_handler(enum nf_conntrack_msg_type type,
struct nf_conntrack *ct, void *data) {
struct ulogd_pluginstance *upi = data;
struct nfct_pluginstance *cpi = (struct nfct_pluginstance *)upi->private;
struct ct_timestamp *ts;
int id, ret;
id = hashtable_hash(cpi->ct_acti... | overrun_handler | ulogd-2.0.7-r3 | app-admin | O0/app-admin/ulogd-2.0.7-r3/ulogd_inpflow_NFCT.so | ida | O0 |
void overrun_timeout(ulogd_timer *a, void *data) {
int family;
ulogd_pluginstance *upi;
nfct_pluginstance *cpi;
unsigned long v5;
v5 = __readfsqword(0x28u);
family = 0;
upi = (ulogd_pluginstance *)data;
cpi = (nfct_pluginstance *)((char *)data + 120);
nfct_send(*((_QWORD *)data + 16), 5, &family);
} | static void overrun_timeout(struct ulogd_timer *a, void *data) {
int family = AF_UNSPEC;
struct ulogd_pluginstance *upi = data;
struct nfct_pluginstance *cpi = (struct nfct_pluginstance *)upi->private;
nfct_send(cpi->ovh, NFCT_Q_DUMP, &family);
} | overrun_timeout | ulogd-2.0.7-r3 | app-admin | O0/app-admin/ulogd-2.0.7-r3/ulogd_inpflow_NFCT.so | ida | O0 |
int polling_handler(nf_conntrack_msg_type type, nf_conntrack *ct, void *data) {
unsigned int id;
nfct_pluginstance *cpi;
ct_timestamp *ts;
ct_timestamp *tsa;
cpi = (nfct_pluginstance *)((char *)data + 120);
if (type != nf_conntrack_msg_type_NFCT_T_UPDATE) {
__ulogd_log(5, "ulogd_inpflow_NFCT.c", 790,
... | static int polling_handler(enum nf_conntrack_msg_type type,
struct nf_conntrack *ct, void *data) {
struct ulogd_pluginstance *upi = data;
struct nfct_pluginstance *cpi = (struct nfct_pluginstance *)upi->private;
struct ct_timestamp *ts;
int ret, id;
switch (type) {
case NFCT_T_UP... | polling_handler | ulogd-2.0.7-r3 | app-admin | O0/app-admin/ulogd-2.0.7-r3/ulogd_inpflow_NFCT.so | ida | O0 |
void polling_timer_cb(ulogd_timer *t, void *data) {
int family;
ulogd_pluginstance *upi;
nfct_pluginstance *cpi;
unsigned long v5;
v5 = __readfsqword(0x28u);
upi = (ulogd_pluginstance *)data;
cpi = (nfct_pluginstance *)((char *)data + 120);
family = 0;
nfct_query(*((_QWORD *)data + 17), 5, &family);
... | static void polling_timer_cb(struct ulogd_timer *t, void *data) {
struct ulogd_pluginstance *upi = data;
struct nfct_pluginstance *cpi = (struct nfct_pluginstance *)upi->private;
int family = AF_UNSPEC;
nfct_query(cpi->pgh, NFCT_Q_DUMP, &family);
hashtable_iterate(cpi->ct_active, upi, do_purge);
ulogd_add_... | polling_timer_cb | ulogd-2.0.7-r3 | app-admin | O0/app-admin/ulogd-2.0.7-r3/ulogd_inpflow_NFCT.so | ida | O0 |
int propagate_ct(ulogd_pluginstance *main_upi, ulogd_pluginstance *upi,
nf_conntrack *ct, int type, ct_timestamp *ts) {
uint8_t attr_u8;
char v6;
uint32_t attr_u32;
uint32_t v8;
uint32_t v9;
uint32_t v10;
const void *attr;
const void *v12;
const void *v13;
const void *v14;
unsigne... | static int propagate_ct(struct ulogd_pluginstance *main_upi,
struct ulogd_pluginstance *upi, struct nf_conntrack *ct,
int type, struct ct_timestamp *ts) {
struct ulogd_key *ret = upi->output.keys;
struct nfct_pluginstance *cpi = (struct nfct_pluginstance *)main_upi->p... | propagate_ct | ulogd-2.0.7-r3 | app-admin | O0/app-admin/ulogd-2.0.7-r3/ulogd_inpflow_NFCT.so | ida | O0 |
int read_cb_nfct(int fd, unsigned int what, void *param) {
ulogd_pluginstance *upi;
upi = (ulogd_pluginstance *)((char *)param - 120);
if ((what & 1) == 0)
return 0;
if ((unsigned int)nfct_catch(*(_QWORD *)param) == -1 &&
*__errno_location() == 105) {
if (upi->config_kset->ces[6].u.value) {
... | static int read_cb_nfct(int fd, unsigned int what, void *param) {
struct nfct_pluginstance *cpi = (struct nfct_pluginstance *)param;
struct ulogd_pluginstance *upi =
container_of(param, struct ulogd_pluginstance, private);
static int warned = 0;
if (!(what & ULOGD_FD_READ))
return 0;
if (nfct_catc... | read_cb_nfct | ulogd-2.0.7-r3 | app-admin | O0/app-admin/ulogd-2.0.7-r3/ulogd_inpflow_NFCT.so | ida | O0 |
int read_cb_ovh(int fd, unsigned int what, void *param) {
ulogd_pluginstance *upi;
upi = (ulogd_pluginstance *)((char *)param - 120);
if ((what & 1) == 0)
return 0;
if ((unsigned int)nfct_catch(*((_QWORD *)param + 1)) == -1 &&
*__errno_location() == 105 &&
!(unsigned int)ulogd_timer_pending((ch... | static int read_cb_ovh(int fd, unsigned int what, void *param) {
struct nfct_pluginstance *cpi = (struct nfct_pluginstance *)param;
struct ulogd_pluginstance *upi =
container_of(param, struct ulogd_pluginstance, private);
if (!(what & ULOGD_FD_READ))
return 0;
if (nfct_catch(cpi->ovh) == -1) {
... | read_cb_ovh | ulogd-2.0.7-r3 | app-admin | O0/app-admin/ulogd-2.0.7-r3/ulogd_inpflow_NFCT.so | ida | O0 |
void set_timestamp_from_ct(ct_timestamp *ts, nf_conntrack *ct, int name) {
if (!set_timestamp_from_ct_try(ts, ct, name))
gettimeofday(&ts->time[name], 0);
} | static void set_timestamp_from_ct(struct ct_timestamp *ts,
struct nf_conntrack *ct, int name) {
if (!set_timestamp_from_ct_try(ts, ct, name))
gettimeofday(&ts->time[name], NULL);
} | set_timestamp_from_ct | ulogd-2.0.7-r3 | app-admin | O0/app-admin/ulogd-2.0.7-r3/ulogd_inpflow_NFCT.so | ida | O0 |
int set_timestamp_from_ct_try(ct_timestamp *ts, nf_conntrack *ct, int name) {
unsigned int attr_name;
if (name)
attr_name = 64;
else
attr_name = 63;
if (!(unsigned int)nfct_attr_is_set(ct, attr_name))
return 0;
ts->time[name].tv_sec = nfct_get_attr_u64(ct, attr_name) / 0x3B9ACA00uLL;
ts->time[n... | static int set_timestamp_from_ct_try(struct ct_timestamp *ts,
struct nf_conntrack *ct, int name) {
int attr_name;
if (name == START)
attr_name = ATTR_TIMESTAMP_START;
else
attr_name = ATTR_TIMESTAMP_STOP;
if (nfct_attr_is_set(ct, attr_name)) {
ts->time[name].tv... | set_timestamp_from_ct_try | ulogd-2.0.7-r3 | app-admin | O0/app-admin/ulogd-2.0.7-r3/ulogd_inpflow_NFCT.so | ida | O0 |
int setnlbufsiz(ulogd_pluginstance *upi, int size) {
long v2;
if (size >= upi->config_kset->ces[6].u.value) {
if (!warned_1) {
warned_1 = 1;
__ulogd_log(5, "ulogd_inpflow_NFCT.c", 813,
"Maximum buffer size (%d) in NFCT has been reached. Please, "
"consider rising... | static int setnlbufsiz(struct ulogd_pluginstance *upi, int size) {
struct nfct_pluginstance *cpi = (struct nfct_pluginstance *)upi->private;
static int warned = 0;
if (size < nlsockbufmaxsize_ce(upi->config_kset).u.value) {
cpi->nlbufsiz = nfnl_rcvbufsiz(nfct_nfnlh(cpi->cth), size);
return 1;
}
if (... | setnlbufsiz | ulogd-2.0.7-r3 | app-admin | O0/app-admin/ulogd-2.0.7-r3/ulogd_inpflow_NFCT.so | ida | O0 |
void signal_nfct(ulogd_pluginstance *pi, int signal) {
if (signal == 12)
get_ctr_zero(pi);
} | static void signal_nfct(struct ulogd_pluginstance *pi, int signal) {
switch (signal) {
case SIGUSR2:
get_ctr_zero(pi);
break;
}
} | signal_nfct | ulogd-2.0.7-r3 | app-admin | O0/app-admin/ulogd-2.0.7-r3/ulogd_inpflow_NFCT.so | ida | O0 |
void init() { ulogd_register_plugin(&xml_plugin); } | void init(void) { ulogd_register_plugin(&xml_plugin); } | init | ulogd-2.0.7-r3 | app-admin | O0/app-admin/ulogd-2.0.7-r3/ulogd_output_XML.so | ida | O0 |
int xml_configure(ulogd_pluginstance *upi, ulogd_pluginstance_stack *stack) {
int ret;
ret = config_parse_file(upi->id, upi->config_kset);
if (ret >= 0)
return 0;
else
return ret;
} | static int xml_configure(struct ulogd_pluginstance *upi,
struct ulogd_pluginstance_stack *stack) {
int ret;
ret = config_parse_file(upi->id, upi->config_kset);
if (ret < 0)
return ret;
return 0;
} | xml_configure | ulogd-2.0.7-r3 | app-admin | O0/app-admin/ulogd-2.0.7-r3/ulogd_output_XML.so | ida | O0 |
int xml_fini(ulogd_pluginstance *pi) {
xml_priv *op;
ulogd_pluginstance *input_plugin;
op = (xml_priv *)pi->private;
input_plugin = (ulogd_pluginstance *)pi->stack->list.next;
if ((input_plugin->plugin->output.type & 8) != 0) {
fwrite("</conntrack>\n", 1u, 0xDu, op->of);
} else if ((input_plugin->plugi... | static int xml_fini(struct ulogd_pluginstance *pi) {
struct xml_priv *op = (struct xml_priv *)&pi->private;
struct ulogd_pluginstance *input_plugin =
llist_entry(pi->stack->list.next, struct ulogd_pluginstance, list);
if (input_plugin->plugin->output.type & ULOGD_DTYPE_FLOW)
fprintf(op->of, "</conntra... | xml_fini | ulogd-2.0.7-r3 | app-admin | O0/app-admin/ulogd-2.0.7-r3/ulogd_output_XML.so | ida | O0 |
int xml_open_file(ulogd_pluginstance *upi) {
void *v1;
char *v2;
FILE *v4;
long v5;
ulogd_pluginstance *upia;
int ret;
time_t now;
xml_priv *op;
const llist_head *__mptr;
ulogd_pluginstance *input_plugin;
long v12;
char (*p_file_infix)[];
tm *tm;
char buf[4096];
char filename[4104];
unsi... | static int xml_open_file(struct ulogd_pluginstance *upi) {
time_t now;
struct tm *tm;
char buf[PATH_MAX], filename[FILENAME_MAX];
struct xml_priv *op = (struct xml_priv *)&upi->private;
int ret;
struct ulogd_pluginstance *input_plugin =
llist_entry(upi->stack->list.next, struct ulogd_pluginstance, li... | xml_open_file | ulogd-2.0.7-r3 | app-admin | O0/app-admin/ulogd-2.0.7-r3/ulogd_output_XML.so | ida | O0 |
int xml_output(ulogd_pluginstance *upi) {
int ret;
ulogd_key *inp;
xml_priv *opi;
inp = upi->input.keys;
opi = (xml_priv *)upi->private;
ret = -1;
if (inp->u.value.ui64 && (*(_WORD *)(inp->u.value.ui64 + 6) & 1) != 0) {
ret = xml_output_flow(inp, buf_0, 4096);
} else if (inp[1].u.value.ui64 &&
... | static int xml_output(struct ulogd_pluginstance *upi) {
struct ulogd_key *inp = upi->input.keys;
struct xml_priv *opi = (struct xml_priv *)&upi->private;
static char buf[4096];
int ret = -1;
if (pp_is_valid(inp, KEY_CT))
ret = xml_output_flow(inp, buf, sizeof(buf));
else if (pp_is_valid(inp, KEY_PCKT))... | xml_output | ulogd-2.0.7-r3 | app-admin | O0/app-admin/ulogd-2.0.7-r3/ulogd_output_XML.so | ida | O0 |
int xml_output_flow(ulogd_key *inp, char *buf, ssize_t size) {
void *ptr;
int tmp;
ptr = ikey_get_ptr(inp);
tmp = nfct_snprintf(buf, (unsigned int)size, ptr, 0, 1, 7);
if (tmp >= 0 && size > tmp)
return 0;
else
return -1;
} | static int xml_output_flow(struct ulogd_key *inp, char *buf, ssize_t size) {
#ifdef BUILD_NFCT
struct nf_conntrack *ct = ikey_get_ptr(&inp[KEY_CT]);
int tmp;
tmp = nfct_snprintf(buf, size, ct, 0, NFCT_O_XML,
NFCT_OF_SHOW_LAYER3 | NFCT_OF_ID | NFCT_OF_TIME);
if (tmp < 0 || tmp >= size)
... | xml_output_flow | ulogd-2.0.7-r3 | app-admin | O0/app-admin/ulogd-2.0.7-r3/ulogd_output_XML.so | ida | O0 |
int xml_output_packet(ulogd_key *inp, char *buf, ssize_t size) {
void *ptr;
int tmp;
ptr = ikey_get_ptr(inp + 1);
tmp = nflog_snprintf_xml(buf, size, ptr, 0xFFFFFFFFLL);
if (tmp >= 0 && size > tmp)
return 0;
else
return -1;
} | static int xml_output_packet(struct ulogd_key *inp, char *buf, ssize_t size) {
#ifdef BUILD_NFLOG
struct nflog_data *ldata = ikey_get_ptr(&inp[KEY_PCKT]);
int tmp;
tmp = nflog_snprintf_xml(buf, size, ldata, NFLOG_XML_ALL);
if (tmp < 0 || tmp >= size)
return -1;
return 0;
#else
return -1;
#endif
} | xml_output_packet | ulogd-2.0.7-r3 | app-admin | O0/app-admin/ulogd-2.0.7-r3/ulogd_output_XML.so | ida | O0 |
int xml_output_sum(ulogd_key *inp, char *buf, ssize_t size) { return -1; } | static int xml_output_sum(struct ulogd_key *inp, char *buf, ssize_t size) {
#ifdef BUILD_NFACCT
struct nfacct *nfacct = ikey_get_ptr(&inp[KEY_SUM]);
int tmp;
tmp = nfacct_snprintf(buf, size, nfacct, NFACCT_SNPRINTF_T_XML,
NFACCT_SNPRINTF_F_TIME);
if (tmp < 0 || tmp >= size)
return -... | xml_output_sum | ulogd-2.0.7-r3 | app-admin | O0/app-admin/ulogd-2.0.7-r3/ulogd_output_XML.so | ida | O0 |
void xml_print_header(ulogd_pluginstance *upi) {
xml_priv *op;
ulogd_pluginstance *input_plugin;
op = (xml_priv *)upi->private;
fwrite("<?xml version=\"1.0\" encoding=\"utf-8\"?>\n", 1u, 0x27u,
*(FILE **)upi->private);
input_plugin = (ulogd_pluginstance *)upi->stack->list.next;
if ((input_plugin->... | static void xml_print_header(struct ulogd_pluginstance *upi) {
struct xml_priv *op = (struct xml_priv *)&upi->private;
fprintf(op->of, "<?xml version=\"1.0\" encoding=\"utf-8\"?>\n");
struct ulogd_pluginstance *input_plugin =
llist_entry(upi->stack->list.next, struct ulogd_pluginstance, list);
if (inpu... | xml_print_header | ulogd-2.0.7-r3 | app-admin | O0/app-admin/ulogd-2.0.7-r3/ulogd_output_XML.so | ida | O0 |
void xml_signal_handler(ulogd_pluginstance *upi, int signal) {
int *v2;
char *v3;
if (signal == 1) {
__ulogd_log(5, "ulogd_output_XML.c", 298, "XML: reopening logfile\n");
xml_fini(upi);
if (xml_open_file(upi) >= 0) {
xml_print_header(upi);
} else {
v2 = __errno_location();
v3 =... | static void xml_signal_handler(struct ulogd_pluginstance *upi, int signal) {
switch (signal) {
case SIGHUP:
ulogd_log(ULOGD_NOTICE, "XML: reopening logfile\n");
xml_fini(upi);
if (xml_open_file(upi) < 0) {
ulogd_log(ULOGD_FATAL, "can't open XML file: %s\n", strerror(errno));
return;
}
... | xml_signal_handler | ulogd-2.0.7-r3 | app-admin | O0/app-admin/ulogd-2.0.7-r3/ulogd_output_XML.so | ida | O0 |
int xml_start(ulogd_pluginstance *upi) {
int *v1;
char *v2;
if (upi->config_kset->ces[2].u.value) {
*(_QWORD *)upi->private = stdout;
} else if (xml_open_file(upi) < 0) {
v1 = __errno_location();
v2 = strerror(*v1);
__ulogd_log(8, "ulogd_output_XML.c", 284, "can't open XML file: %s\n", v2);
... | static int xml_start(struct ulogd_pluginstance *upi) {
struct xml_priv *op = (struct xml_priv *)&upi->private;
if (upi->config_kset->ces[CFG_XML_STDOUT].u.value != 0) {
op->of = stdout;
} else {
if (xml_open_file(upi) < 0) {
ulogd_log(ULOGD_FATAL, "can't open XML file: %s\n", strerror(errno));
... | xml_start | ulogd-2.0.7-r3 | app-admin | O0/app-admin/ulogd-2.0.7-r3/ulogd_output_XML.so | ida | O0 |
void compute_ext_disk_stats(stats_disk *sdc, stats_disk *sdp, unsigned long itv,
ext_disk_stats *xds) {
double v4;
unsigned long nr_ios;
unsigned long v6;
long v7;
double v8;
unsigned long v9;
long v10;
double v11;
if ((itv & 0x8000000000000000LL) != 0LL)
v4 = (double)... | void compute_ext_disk_stats(struct stats_disk *sdc, struct stats_disk *sdp,
unsigned long long itv,
struct ext_disk_stats *xds) {
xds->util = S_VALUE(sdp->tot_ticks, sdc->tot_ticks, itv);
xds->await =
(sdc->nr_ios - sdp->nr_ios)
? ((sdc->rd_ti... | compute_ext_disk_stats | sysstat-12.5.4 | app-admin | O0/app-admin/sysstat-12.5.4/cifsiostat | ida | O0 |
unsigned long get_per_cpu_interval(stats_cpu *scc, stats_cpu *scp) {
unsigned long cpu_user;
unsigned long v5;
unsigned long v6;
unsigned long cpu_nice;
unsigned long v8;
unsigned long v9;
unsigned long cpu_guest_nice;
unsigned long v11;
unsigned long cpu_iowait;
unsigned long v13;
unsigned long c... | unsigned long long get_per_cpu_interval(struct stats_cpu *scc,
struct stats_cpu *scp) {
unsigned long long ishift = 0LL;
if ((scc->cpu_user - scc->cpu_guest) < (scp->cpu_user - scp->cpu_guest)) {
ishift +=
(scp->cpu_user - scp->cpu_guest) - (scc->cpu_user - scc-... | get_per_cpu_interval | sysstat-12.5.4 | app-admin | O0/app-admin/sysstat-12.5.4/cifsiostat | ida | O0 |
char *get_persistent_name_from_pretty(char *pretty) {
char **persistent_names;
char *v3;
void **v4;
char **v5;
char *persistent_name_path;
ssize_t v7;
char *v8;
void *v9;
void **i;
char *result;
char target[4104];
unsigned long v13;
v13 = __readfsqword(0x28u);
persist_name_6[0] = 0;
persi... | char *get_persistent_name_from_pretty(char *pretty) {
int i = -1;
ssize_t r;
char *link, *name;
char **persist_names;
char target[PATH_MAX];
static char persist_name[FILENAME_MAX];
persist_name[0] = '\0';
persist_names = get_persistent_names();
if (!persist_names)
return (NULL);
while (persis... | get_persistent_name_from_pretty | sysstat-12.5.4 | app-admin | O0/app-admin/sysstat-12.5.4/cifsiostat | ida | O0 |
int ioc_init() {
FILE *v0;
FILE *v1;
ioc_entry *v2;
char *v3;
int v4;
int v5;
char *v6;
char v7;
char *v8;
__m128i v9;
long v10;
__m128i v11;
__m128i v12;
__m128i v13;
unsigned int v14;
long v15;
long v16;
ioc_entry *v17;
__m128i *v18;
blk_config *blkp;
ioc_entry *v21;
blk_co... | int ioc_init(void) {
FILE *fp;
unsigned int i, major, indirect, count = 0;
char buf[IOC_LINESIZ];
char cfmt[IOC_FMTLEN];
char dfmt[IOC_FMTLEN];
char pfmt[IOC_FMTLEN];
char desc[IOC_DESCLEN];
struct ioc_entry *iocp = NULL;
struct blk_config *blkp = NULL;
char ioconf_name[64];
if ((fp = fopen(IOCON... | ioc_init | sysstat-12.5.4 | app-admin | O0/app-admin/sysstat-12.5.4/cifsiostat | ida | O0 |
char *ioc_ito10(unsigned int n) {
char *v1;
unsigned int v2;
byte_10340 = 0;
v1 = &byte_10340;
if (n) {
do {
*--v1 = accept[n % 0xA + 1];
v2 = n;
n /= 0xAu;
} while (v2 > 9);
return v1;
} else {
byte_1033F = 48;
return &byte_10340 - 1;
}
} | char *ioc_ito10(unsigned int n) { return (ioc_conv(10, 0, "0123456789", n)); } | ioc_ito10 | sysstat-12.5.4 | app-admin | O0/app-admin/sysstat-12.5.4/cifsiostat | ida | O0 |
char *ioc_ito26(unsigned int n) {
char *v1;
unsigned int v2;
byte_10340 = 0;
v1 = &byte_10340;
v2 = n + 1;
if (n != -1) {
do {
*--v1 = aZabcdefghijklm[v2 % 0x1A];
v2 = (__PAIR64__(v2 / 0x1A, v2 % 0x1A) - 1) >> 32;
} while (v2);
}
return v1;
} | char *ioc_ito26(unsigned int n) {
return (ioc_conv(26, 1, "zabcdefghijklmnopqrstuvwxy", n));
} | ioc_ito26 | sysstat-12.5.4 | app-admin | O0/app-admin/sysstat-12.5.4/cifsiostat | ida | O0 |
char *ioc_name(unsigned int major, unsigned int minor) {
long v2;
ioc_entry *v4;
blk_config *v5;
unsigned int dcount;
unsigned int pcount;
long ctrlno;
long v9;
unsigned int v10;
long v11;
char *v12;
long v13;
size_t v14;
blk_config *blkp;
size_t v17;
v2 = major;
if (major > 0x1FF || mi... | char *ioc_name(unsigned int major, unsigned int minor) {
static char name[IOC_DEVLEN];
struct ioc_entry *p;
int base, offset;
if ((major > MAX_BLKDEV) || (minor > IOC_MAXMINOR)) {
return (NULL);
}
if (!ioc_parsed && !ioc_init())
return (NULL);
p = ioconf[major];
if ((p == NULL) || ((minor & ... | ioc_name | sysstat-12.5.4 | app-admin | O0/app-admin/sysstat-12.5.4/cifsiostat | ida | O0 |
int main(int argc, const char **argv, const char **envp) {
const char **v4;
int v5;
int v6;
const char *v7;
int v8;
long v9;
size_t v11;
long v12;
char v13;
long v14;
int opt;
long count;
long counta;
const char *v18;
tm rectime;
utsname header;
unsigned long v22;
v22 = __readfsqwor... | int main(int argc, char **argv) {
int it = 0;
int opt = 1;
int i;
long count = 1;
struct utsname header;
struct tm rectime;
#ifdef USE_NLS
init_nls();
#endif
init_colors();
while (opt < argc) {
#ifdef DEBUG
if (!strcmp(argv[opt], "--debuginfo")) {
flags |= I_D_DEBUG;
opt++;
} ... | main | sysstat-12.5.4 | app-admin | O0/app-admin/sysstat-12.5.4/cifsiostat | ida | O0 |
void read_cifs_stat(int curr) {
FILE *v1;
FILE *v2;
int v3;
io_cifs *v4;
__m128i *v5;
io_cifs *v6;
__m128i *v7;
unsigned long aux_open;
unsigned long all_open;
cifs_st scifs;
char aux[32];
char cifs_name[128];
char name_tmp[128];
char line[256];
unsigned long v15;
v15 = __readfsqword(0x... | void read_cifs_stat(int curr) {
FILE *fp;
char line[256];
char aux[32];
int start = 0;
long long unsigned aux_open;
long long unsigned all_open = 0;
char cifs_name[MAX_NAME_LEN];
char name_tmp[MAX_NAME_LEN];
struct cifs_st scifs;
struct io_cifs *ci;
if ((fp = fopen(CIFSSTATS, "r")) == NULL)
r... | read_cifs_stat | sysstat-12.5.4 | app-admin | O0/app-admin/sysstat-12.5.4/cifsiostat | ida | O0 |
int read_meminfo(stats_memory *st_memory) {
FILE *v1;
FILE *v2;
char line[136];
unsigned long v5;
v5 = __readfsqword(0x28u);
v1 = fopen("/proc/meminfo", "r");
if (!v1)
return 0;
v2 = v1;
while (fgets(line, 128, v2)) {
if (*(_QWORD *)line == 0x6C61746F546D654DLL && line[8] == 58) {
__iso... | __nr_t read_meminfo(struct stats_memory *st_memory) {
FILE *fp;
char line[128];
if ((fp = fopen(MEMINFO, "r")) == NULL)
return 0;
while (fgets(line, sizeof(line), fp) != NULL) {
if (!strncmp(line, "MemTotal:", 9)) {
sscanf(line + 9, "%llu", &st_memory->tlmkb);
} else if (!strncmp(line, "Me... | read_meminfo | sysstat-12.5.4 | app-admin | O0/app-admin/sysstat-12.5.4/cifsiostat | ida | O0 |
int read_stat_cpu(stats_cpu *st_cpu, int nr_alloc) {
FILE *v2;
FILE *v3;
int v4;
__m128i v5;
__m128i v6;
__m128i v7;
__m128i v8;
__m128i v9;
stats_cpu *v10;
int *v12;
char *v13;
int proc_nr;
stats_cpu sc;
char line[8200];
unsigned long v17;
v17 = __readfsqword(0x28u);
v2 = fopen("/pro... | __nr_t read_stat_cpu(struct stats_cpu *st_cpu, __nr_t nr_alloc) {
FILE *fp;
struct stats_cpu *st_cpu_i;
struct stats_cpu sc;
char line[8192];
int proc_nr;
__nr_t cpu_read = 0;
if ((fp = fopen(STAT, "r")) == NULL) {
fprintf(stderr, _("Cannot open %s: %s\n"), STAT, strerror(errno));
exit(2);
}
... | read_stat_cpu | sysstat-12.5.4 | app-admin | O0/app-admin/sysstat-12.5.4/cifsiostat | ida | O0 |
int read_stat_irq(stats_irq *st_irq, int nr_alloc) {
FILE *v2;
FILE *v3;
int v4;
stats_irq *v5;
unsigned int v6;
int v7;
unsigned long irq_nr;
char line[8200];
unsigned long v11;
v11 = __readfsqword(0x28u);
v2 = fopen("/proc/stat", "r");
if (!v2)
return 0;
v3 = v2;
do {
if (!fgets(l... | __nr_t read_stat_irq(struct stats_irq *st_irq, __nr_t nr_alloc) {
FILE *fp;
struct stats_irq *st_irq_i;
char line[8192];
int i, pos;
unsigned long long irq_nr;
__nr_t irq_read = 0;
if ((fp = fopen(STAT, "r")) == NULL)
return 0;
while (fgets(line, sizeof(line), fp) != NULL) {
if (!strncmp(line... | read_stat_irq | sysstat-12.5.4 | app-admin | O0/app-admin/sysstat-12.5.4/cifsiostat | ida | O0 |
void read_uptime(unsigned long *uptime) {
FILE *v1;
FILE *v2;
char *v3;
unsigned long up_sec;
unsigned long up_cent;
char line[136];
unsigned long v7;
v7 = __readfsqword(0x28u);
v1 = fopen("/proc/uptime", "r");
if (!v1) {
LABEL_5:
v3 = dcgettext(0, "Cannot read %s\n", 5);
__fprintf_chk(st... | void read_uptime(unsigned long long *uptime) {
FILE *fp = NULL;
char line[128];
unsigned long up_sec, up_cent;
int err = FALSE;
if ((fp = fopen(UPTIME, "r")) == NULL) {
err = TRUE;
} else if (fgets(line, sizeof(line), fp) == NULL) {
err = TRUE;
} else if (sscanf(line, "%lu.%lu", &up_sec, &up_cent... | read_uptime | sysstat-12.5.4 | app-admin | O0/app-admin/sysstat-12.5.4/cifsiostat | ida | O0 |
void rw_io_stat_loop(long count, tm *rectime) {
int v2;
io_cifs *i;
v2 = 1;
memset(&alrm_act.sa_mask, 0, 0x90u);
alrm_act.sa_handler = alarm_handler;
sigaction(14, &alrm_act, 0);
alarm(interval);
while (1) {
for (i = cifs_list; i; i = i->next)
i->exist = 0;
read_uptime(&uptime_cs[v2]);
... | void rw_io_stat_loop(long int count, struct tm *rectime) {
int curr = 1;
memset(&alrm_act, 0, sizeof(alrm_act));
alrm_act.sa_handler = alarm_handler;
sigaction(SIGALRM, &alrm_act, NULL);
alarm(interval);
do {
set_cifs_nonexistent(cifs_list);
read_uptime(&(uptime_cs[curr]));
read_cifs_stat(c... | rw_io_stat_loop | sysstat-12.5.4 | app-admin | O0/app-admin/sysstat-12.5.4/cifsiostat | ida | O0 |
void set_cifs_nonexistent(io_cifs *clist) {
while (clist) {
clist->exist = 0;
clist = clist->next;
}
} | void set_cifs_nonexistent(struct io_cifs *clist) {
while (clist != NULL) {
clist->exist = FALSE;
clist = clist->next;
}
} | set_cifs_nonexistent | sysstat-12.5.4 | app-admin | O0/app-admin/sysstat-12.5.4/cifsiostat | ida | O0 |
void usage(char *progname) {
char *v1;
char *v2;
long v3;
v1 = dcgettext(0, "Usage: %s [ options ] [ <interval> [ <count> ] ]\n", 5);
__fprintf_chk(stderr, 1, v1, progname);
v2 = dcgettext(0,
"Options are:\n[ --dec={ 0 | 1 | 2 } ] [ --human ] [ --pretty "
"]\n[ -h ] [ -k |... | void usage(char *progname) {
fprintf(stderr, _("Usage: %s [ options ] [ <interval> [ <count> ] ]\n"),
progname);
#ifdef DEBUG
fprintf(stderr, _("Options are:\n"
"[ --dec={ 0 | 1 | 2 } ] [ --human ] [ --pretty ]\n"
"[ -h ] [ -k | -m ] [ -t ] [ -V ] [ --debuginfo ]\n... | usage | sysstat-12.5.4 | app-admin | O0/app-admin/sysstat-12.5.4/cifsiostat | ida | O0 |
void write_cifs_stat(int curr, unsigned long itv, int fctr, io_cifs *clist,
cifs_st *ioni, cifs_st *ionj) {
char v10;
double v11;
signed long v12;
double v13;
double v14;
unsigned long v15;
double v16;
int v17;
double v18;
unsigned long v19;
double v20;
double v21;
unsigne... | void write_cifs_stat(int curr, unsigned long long itv, int fctr,
struct io_cifs *clist, struct cifs_st *ioni,
struct cifs_st *ionj) {
double rbytes, wbytes;
if (!DISPLAY_PRETTY(flags)) {
cprintf_in(IS_STR, "%-22s", clist->name, 0);
}
rbytes = S_VALUE(ionj->rd_byte... | write_cifs_stat | sysstat-12.5.4 | app-admin | O0/app-admin/sysstat-12.5.4/cifsiostat | ida | O0 |
void write_cifs_stat_header(int *fctr) {
char v1;
v1 = flags;
if ((flags & 0x10) == 0) {
__printf_chk(1, "Filesystem ");
v1 = flags;
}
if ((v1 & 2) != 0) {
__printf_chk(1, " rkB/s wkB/s");
*fctr = 1024;
} else if ((v1 & 4) != 0) {
__printf_chk(1, " rMB/s ... | void write_cifs_stat_header(int *fctr) {
if (!DISPLAY_PRETTY(flags)) {
printf("Filesystem ");
}
if (DISPLAY_KILOBYTES(flags)) {
printf(" rkB/s wkB/s");
*fctr = 1024;
} else if (DISPLAY_MEGABYTES(flags)) {
printf(" rMB/s wMB/s");
*fctr = 1024 * 1024;
}... | write_cifs_stat_header | sysstat-12.5.4 | app-admin | O0/app-admin/sysstat-12.5.4/cifsiostat | ida | O0 |
void write_stats(int curr, tm *rectime) {
_BOOL8 v2;
unsigned long interval;
io_cifs *v4;
_BOOL8 v5;
int fctr;
unsigned long v7;
v7 = __readfsqword(0x28u);
fctr = 1;
if (write(1, "", 0) == -1) {
perror("stdout");
exit(6);
}
if ((flags & 1) != 0) {
if ((flags & 8) != 0)
strftime(... | void write_stats(int curr, struct tm *rectime) {
int fctr = 1;
unsigned long long itv;
struct io_cifs *clist;
struct cifs_st *ioni, *ionj;
TEST_STDOUT(STDOUT_FILENO);
if (DISPLAY_TIMESTAMP(flags)) {
if (DISPLAY_ISO(flags)) {
strftime(timestamp, sizeof(timestamp), "%FT%T%z", rectime);
} else ... | write_stats | sysstat-12.5.4 | app-admin | O0/app-admin/sysstat-12.5.4/cifsiostat | ida | O0 |
int accept_to_accept(fa *fa) {
state *a;
state *s;
s = add_state(fa, 0);
if (!s)
return -1;
if (mark_reachable(fa) < 0)
return -1;
for (a = fa->initial; a; a = a->next) {
if ((*((_BYTE *)a + 16) & 1) != 0 && (*((_BYTE *)a + 16) & 4) != 0 &&
add_epsilon_trans(s, a) < 0)
return -1;
... | static int accept_to_accept(struct fa *fa) {
int r;
struct state *s = add_state(fa, 0);
if (s == NULL)
return -1;
F(mark_reachable(fa));
list_for_each(a, fa->initial) {
if (a->accept && a->reachable) {
r = add_epsilon_trans(s, a);
if (r < 0)
return -1;
}
}
set_initial(fa,... | accept_to_accept | augeas-1.12.0 | app-admin | O0/app-admin/augeas-1.12.0/libfa.so.1.5.3 | ida | O0 |
int add_crash_trans(fa *fa, state *s, state *crash, int min, int max) {
uchar maxa;
int result;
maxa = max;
if ((*((_BYTE *)fa + 8) & 4) == 0 || min > 90 || max <= 64)
return add_new_trans(s, crash, min, max);
if (min > 64 && max <= 90)
return 0;
if (max <= 90)
return add_new_trans(s, crash, mi... | static int add_crash_trans(struct fa *fa, struct state *s, struct state *crash,
int min, int max) {
int result;
if (fa->nocase) {
if (min > 'Z' || max < 'A') {
result = add_new_trans(s, crash, min, max);
} else if (min >= 'A' && max <= 'Z') {
result = 0;
} else i... | add_crash_trans | augeas-1.12.0 | app-admin | O0/app-admin/augeas-1.12.0/libfa.so.1.5.3 | ida | O0 |
int add_epsilon_trans(state *from, state *to) {
trans *t;
*((_BYTE *)from + 16) = *((_BYTE *)to + 16) & 1 | *((_BYTE *)from + 16) & 1 |
*((_BYTE *)from + 16) & 0xFE;
for (t = to->trans; t - to->trans < to->tused; ++t) {
if (add_new_trans(from, t->to, t->min, t->max) < 0)
retur... | ATTRIBUTE_RETURN_CHECK
static int add_epsilon_trans(struct state *from, struct state *to) {
int r;
from->accept |= to->accept;
for_each_trans(t, to) {
r = add_new_trans(from, t->to, t->min, t->max);
if (r < 0)
return -1;
}
return 0;
} | add_epsilon_trans | augeas-1.12.0 | app-admin | O0/app-admin/augeas-1.12.0/libfa.so.1.5.3 | ida | O0 |
int add_new_re_trans(state *s1, state *s2, re *re) {
if (add_new_trans(s1, s2, 0, 0) < 0)
return -1;
s1->trans[s1->tused - 1].re = re;
return 0;
} | ATTRIBUTE_RETURN_CHECK
static int add_new_re_trans(struct state *s1, struct state *s2, struct re *re) {
int r;
r = add_new_trans(s1, s2, 0, 0);
if (r < 0)
return -1;
last_trans(s1)->re = re;
return 0;
} | add_new_re_trans | augeas-1.12.0 | app-admin | O0/app-admin/augeas-1.12.0/libfa.so.1.5.3 | ida | O0 |
int add_new_trans(state *from, state *to, uchar min, uchar max) {
size_t tsize;
long tsizea;
if (!to)
__assert_fail("to != NULL", "fa.c", 0x1C1u, "add_new_trans");
if (from->tused == from->tsize) {
tsize = from->tsize;
if (tsize) {
if (from->tsize <= 0x80)
tsizea = 2 * tsize;
el... | t++)
ATTRIBUTE_RETURN_CHECK
static int add_new_trans(struct state *from, struct state *to,
uchar min, uchar max) {
assert(to != NULL);
if (from->tused == from->tsize) {
size_t tsize = from->tsize;
if (tsize == 0)
tsize = array_ini... | add_new_trans | augeas-1.12.0 | app-admin | O0/app-admin/augeas-1.12.0/libfa.so.1.5.3 | ida | O0 |
void add_re_char(re *re, uchar from, uchar to) {
unsigned int c;
if (re->type != re_type_CSET)
__assert_fail("re->type == CSET", "fa.c", 0xCF2u, "add_re_char");
for (c = from; c <= to; ++c)
bitset_set(re->cset, c);
} | static void add_re_char(struct re *re, uchar from, uchar to) {
assert(re->type == CSET);
for (unsigned int c = from; c <= to; c++)
bitset_set(re->cset, c);
} | add_re_char | augeas-1.12.0 | app-admin | O0/app-admin/augeas-1.12.0/libfa.so.1.5.3 | ida | O0 |
state *add_state(fa *fa, int accept) {
state *s;
s = make_state();
if (s) {
*((_BYTE *)s + 16) = accept & 1 | *((_BYTE *)s + 16) & 0xFE;
if (fa->initial) {
s->next = fa->initial->next;
fa->initial->next = s;
} else {
fa->initial = s;
}
}
return s;
} | static struct state *add_state(struct fa *fa, int accept) {
struct state *s = make_state();
if (s) {
s->accept = accept;
if (fa->initial == NULL) {
fa->initial = s;
} else {
list_cons(fa->initial->next, s);
}
... | add_state | augeas-1.12.0 | app-admin | O0/app-admin/augeas-1.12.0/libfa.so.1.5.3 | ida | O0 |
bitset *alphabet(fa *fa) {
int i;
uint c;
state *s;
bitset *bs;
bs = bitset_init(0x100u);
if (!bs)
return 0;
for (s = fa->initial; s; s = s->next) {
for (i = 0; i < s->tused; ++i) {
for (c = s->trans[i].min; c <= s->trans[i].max; ++c)
bitset_set(bs, c);
}
}
return bs;
} | static bitset *alphabet(struct fa *fa) {
bitset *bs = bitset_init(UCHAR_NUM);
if (bs == NULL)
return NULL;
list_for_each(s, fa->initial) {
for (int i = 0; i < s->tused; i++) {
for (uint c = s->trans[i].min; c <= s->trans[i].max; c++)
... | alphabet | augeas-1.12.0 | app-admin | O0/app-admin/augeas-1.12.0/libfa.so.1.5.3 | ida | O0 |
char *asnprintf(char *resultbuf, size_t *lengthp, const char *format, ...) {
long v3;
long v4;
long v5;
va_list args;
unsigned long v8;
long v9;
long v10;
long v11;
va_start(args, format);
v3 = va_arg(args, _QWORD);
v4 = va_arg(args, _QWORD);
v5 = va_arg(args, _QWORD);
v9 = v3;
v10 = v4;
... | char *asnprintf(char *resultbuf, size_t *lengthp, const char *format,
...) {
va_list args;
char *result;
va_start(args, format);
result = vasnprintf(resultbuf, lengthp, format, args);
va_end(args);
return result;
} | asnprintf | augeas-1.12.0 | app-admin | O0/app-admin/augeas-1.12.0/libfa.so.1.5.3 | ida | O0 |
size_t base_len(const char *name) {
size_t len;
for (len = strlen(name); len > 1 && name[len - 1] == 47; --len)
;
return len;
} | size_t base_len(char const *name) {
size_t len;
size_t prefix_len = FILE_SYSTEM_PREFIX_LEN(name);
for (len = strlen(name); 1 < len && ISSLASH(name[len - 1]); len--)
continue;
if (DOUBLE_SLASH_IS_DISTINCT_ROOT && len == 1 && ISSLASH(name[0]) &&
IS... | base_len | augeas-1.12.0 | app-admin | O0/app-admin/augeas-1.12.0/libfa.so.1.5.3 | ida | O0 |
void bitset_clr(bitset *bs, unsigned int bit) {
bs[bit >> 5] &= ~(1 << (bit & 0x1F));
} | static inline void bitset_clr(bitset *bs, unsigned int bit) {
bs[bit / UINT_BIT] &= ~(1 << (bit % UINT_BIT));
} | bitset_clr | augeas-1.12.0 | app-admin | O0/app-admin/augeas-1.12.0/libfa.so.1.5.3 | ida | O0 |
bool bitset_disjoint(const bitset *const bs1, const bitset *const bs2,
size_t nbits) {
int i;
for (i = 0; i < (nbits + 32) >> 5; ++i) {
if ((bs1[i] & bs2[i]) != 0)
return 0;
}
return 1;
} | ATTRIBUTE_PURE
static inline bool bitset_disjoint(const bitset *const bs1,
const bitset *const bs2,
size_t nbits) {
for (int i = 0; i < (nbits + UINT_BIT) / UINT_BIT; i++) {
if (bs1[i] & bs2[i])
... | bitset_disjoint | augeas-1.12.0 | app-admin | O0/app-admin/augeas-1.12.0/libfa.so.1.5.3 | ida | O0 |
void bitset_free(bitset *bs) { free(bs); } | static void bitset_free(bitset *bs) { free(bs); } | bitset_free | augeas-1.12.0 | app-admin | O0/app-admin/augeas-1.12.0/libfa.so.1.5.3 | ida | O0 |
int bitset_get(const bitset *const bs, unsigned int bit) {
return (bs[bit >> 5] >> (bit & 0x1F)) & 1;
} | ATTRIBUTE_PURE
static inline int bitset_get(const bitset *const bs,
unsigned int bit) {
return (bs[bit / UINT_BIT] >> bit % UINT_BIT) & 1;
} | bitset_get | augeas-1.12.0 | app-admin | O0/app-admin/augeas-1.12.0/libfa.so.1.5.3 | ida | O0 |
bitset *bitset_init(size_t nbits) {
bitset *bs[2];
bs[1] = (bitset *)__readfsqword(0x28u);
if (mem_alloc_n(bs, 4u, (nbits + 32) >> 5) == -1)
return 0;
else
return bs[0];
} | static bitset *bitset_init(size_t nbits) {
bitset *bs;
if (ALLOC_N(bs, (nbits + UINT_BIT) / UINT_BIT) == -1)
return NULL;
return bs;
} | bitset_init | augeas-1.12.0 | app-admin | O0/app-admin/augeas-1.12.0/libfa.so.1.5.3 | ida | O0 |
void bitset_negate(bitset *bs, size_t nbits) {
int i;
for (i = 0; i < (nbits + 32) >> 5; ++i)
bs[i] = ~bs[i];
} | static void bitset_negate(bitset *bs, size_t nbits) {
for (int i = 0; i < (nbits + UINT_BIT) / UINT_BIT; i++)
bs[i] = ~bs[i];
} | bitset_negate | augeas-1.12.0 | app-admin | O0/app-admin/augeas-1.12.0/libfa.so.1.5.3 | ida | O0 |
int case_expand(fa *fa) {
char v2;
uchar v3;
int i;
int tused;
uchar lc_min;
state *s;
trans *t;
if ((*((_BYTE *)fa + 8) & 4) == 0)
return 0;
*((_BYTE *)fa + 8) &= ~4u;
for (s = fa->initial; s; s = s->next) {
tused = s->tused;
for (i = 0; i < tused; ++i) {
t = &s->trans[i];
... | static int case_expand(struct fa *fa) {
if (!fa->nocase)
return 0;
fa->nocase = 0;
list_for_each(s, fa->initial) {
int tused = s->tused;
for (int i = 0; i < tused; i++) {
struct trans *t = s->trans + i;
int lc_min = ... | case_expand | augeas-1.12.0 | app-admin | O0/app-admin/augeas-1.12.0/libfa.so.1.5.3 | ida | O0 |
unsigned int chr_score(char c) {
if (((*__ctype_b_loc())[c] & 0x400) != 0)
return 2;
if (((*__ctype_b_loc())[c] & 8) != 0)
return 3;
if (((*__ctype_b_loc())[c] & 0x4000) != 0)
return 7;
if (c)
return 100;
return 10000;
} | static unsigned int chr_score(char c) {
if (isalpha(c)) {
return 2;
} else if (isalnum(c)) {
return 3;
} else if (isprint(c)) {
return 7;
} else if (c == '\0') {
return 10000;
} else {
return 100;
... | chr_score | augeas-1.12.0 | app-admin | O0/app-admin/augeas-1.12.0/libfa.so.1.5.3 | ida | O0 |
void clear_table(hash_t *hash) {
hashcount_t i;
for (i = 0; i < hash->hash_nchains; ++i)
hash->hash_table[i] = 0;
} | static void clear_table(hash_t *hash) {
hash_val_t i;
for (i = 0; i < hash->nchains; i++)
hash->table[i] = NULL;
} | clear_table | augeas-1.12.0 | app-admin | O0/app-admin/augeas-1.12.0/libfa.so.1.5.3 | ida | O0 |
int collect(fa *fa) {
state *s;
state *_p;
if (mark_live(fa) < 0)
return -1;
if ((*((_BYTE *)fa->initial + 16) & 2) != 0) {
collect_trans(fa);
collect_dead_states(fa);
} else {
for (s = fa->initial; s; s = s->next)
free_trans(s);
while (fa->initial->next) {
_p = fa->initial->n... | static int collect(struct fa *fa) {
F(mark_live(fa));
if (!fa->initial->live) {
list_for_each(s, fa->initial) { free_trans(s); }
list_free(fa->initial->next);
fa->deterministic = 1;
} else {
collect_trans(fa);
collect_de... | collect | augeas-1.12.0 | app-admin | O0/app-admin/augeas-1.12.0/libfa.so.1.5.3 | ida | O0 |
void collect_dead_states(fa *fa) {
state *s;
state *del;
s = fa->initial;
while (s->next) {
if ((*((_BYTE *)s->next + 16) & 2) != 0) {
s = s->next;
} else {
del = s->next;
s->next = s->next->next;
free_trans(del);
free(del);
}
}
} | static void collect_dead_states(struct fa *fa) {
for (struct state *s = fa->initial; s->next != NULL;) {
if (!s->next->live) {
struct state *del = s->next;
s->next = del->next;
free_trans(del);
free(del);
} else {
... | collect_dead_states | augeas-1.12.0 | app-admin | O0/app-admin/augeas-1.12.0/libfa.so.1.5.3 | ida | O0 |
void collect_trans(fa *fa) {
trans *v1;
trans *v2;
state *to;
re *re;
int i;
state *s;
for (s = fa->initial; s; s = s->next) {
if ((*((_BYTE *)s + 16) & 2) != 0) {
i = 0;
while (i < s->tused) {
if ((*((_BYTE *)s->trans[i].to + 16) & 2) != 0) {
++i;
} else {
... | static void collect_trans(struct fa *fa) {
list_for_each(s, fa->initial) {
if (!s->live) {
free_trans(s);
} else {
int i = 0;
while (i < s->tused) {
if (!s->trans[i].to->live) {
s->tused -= 1;
... | collect_trans | augeas-1.12.0 | app-admin | O0/app-admin/augeas-1.12.0/libfa.so.1.5.3 | ida | O0 |
void compute_bits() {
int bits;
hash_val_t val;
val = -1;
bits = 0;
while (val) {
++bits;
val >>= 1;
}
hash_val_t_bit = bits;
} | static void compute_bits(void) {
hash_val_t val = HASH_VAL_T_MAX;
int bits = 0;
while (val) {
bits++;
val >>= 1;
}
hash_val_t_bit = bits;
} | compute_bits | augeas-1.12.0 | app-admin | O0/app-admin/augeas-1.12.0/libfa.so.1.5.3 | ida | O0 |
hash_val_t compute_mask(hashcount_t size) {
if (!is_power_of_two(size))
__assert_fail("is_power_of_two(size)", "hash.c", 0x7Bu, "compute_mask");
if (size <= 1)
__assert_fail("size >= 2", "hash.c", 0x7Cu, "compute_mask");
return size - 1;
} | static hash_val_t compute_mask(hashcount_t size) {
assert(is_power_of_two(size));
assert(size >= 2);
return size - 1;
} | compute_mask | augeas-1.12.0 | app-admin | O0/app-admin/augeas-1.12.0/libfa.so.1.5.3 | ida | O0 |
int concat_in_place(fa *fa1, fa **fa2) {
state *s;
if (((*((_BYTE *)fa1 + 8) & 4) != 0) == ((*((_BYTE *)*fa2 + 8) & 4) != 0))
goto LABEL_6;
if (case_expand(fa1) < 0)
return -1;
if (case_expand(*fa2) < 0)
return -1;
LABEL_6:
for (s = fa1->initial; s; s = s->next) {
if ((*((_BYTE *)s + 16) & 1)... | ATTRIBUTE_RETURN_CHECK
static int concat_in_place(struct fa *fa1, struct fa **fa2) {
int r;
if (fa1->nocase != (*fa2)->nocase) {
if (case_expand(fa1) < 0)
return -1;
if (case_expand(*fa2) < 0)
return -1;
}
lis... | concat_in_place | augeas-1.12.0 | app-admin | O0/app-admin/augeas-1.12.0/libfa.so.1.5.3 | ida | O0 |
int convert_strings(fa *fa) {
int result;
int i;
int j;
state *s;
state *s_0;
trans *t;
state *s_1;
trans *t_0;
state *to;
state *s_2;
state_set *worklist;
state *del;
worklist = state_set_init(-1, 0);
result = -1;
if (worklist) {
for (s = fa->initial; s; s = s->next) {
s->hash ... | static int convert_strings(struct fa *fa) {
struct state_set *worklist = state_set_init(-1, S_NONE);
int result = -1;
E(worklist == NULL);
list_for_each(s, fa->initial) {
s->hash = 0;
s->reachable = 0;
}
list_for_each(s, fa->... | convert_strings | augeas-1.12.0 | app-admin | O0/app-admin/augeas-1.12.0/libfa.so.1.5.3 | ida | O0 |
int convert_trans_to_re(state *s) {
re *v2;
trans *v3;
re *v4;
uchar chr;
int i;
int tind;
int t_0;
int cnt;
signed int c;
int i_0;
trans *trans;
re *re;
size_t nto;
state *to;
trans *t;
unsigned long v17;
v17 = __readfsqword(0x28u);
re = 0;
nto = 1;
trans = 0;
if (!s->tused)
... | static int convert_trans_to_re(struct state *s) {
struct re *re = NULL;
size_t nto = 1;
struct trans *trans = NULL;
int r;
if (s->tused == 0)
return 0;
qsort(s->trans, s->tused, sizeof(*s->trans), trans_to_cmp);
for (int i = 0; ... | convert_trans_to_re | augeas-1.12.0 | app-admin | O0/app-admin/augeas-1.12.0/libfa.so.1.5.3 | ida | O0 |
bool cset_contains(const re *cset, int c) {
return bitset_get(cset->cset, c) != cset->c;
} | static bool cset_contains(const struct re *cset, int c) {
return bitset_get(cset->cset, c) != cset->negate;
} | cset_contains | augeas-1.12.0 | app-admin | O0/app-admin/augeas-1.12.0/libfa.so.1.5.3 | ida | O0 |
int determinize(fa *fa, state_set *ini) {
state_set *v3;
state_set *inia;
uchar max;
int npoints;
int ret;
int q;
int n;
int q_1;
int make_ini;
state_set_hash *newstate;
state_set_list *worklist;
trans *t;
const uchar *points;
state_set *sset;
state *r;
state_set *pset;
state *q_0;
u... | static int determinize(struct fa *fa, struct state_set *ini) {
int npoints;
int make_ini = (ini == NULL);
const uchar *points = NULL;
state_set_hash *newstate = NULL;
struct state_set_list *worklist = NULL;
int ret = 0;
if (fa->deterministic)... | determinize | augeas-1.12.0 | app-admin | O0/app-admin/augeas-1.12.0/libfa.so.1.5.3 | ida | O0 |
size_t dir_len(const char *file) {
unsigned long length;
size_t prefix_length;
prefix_length = *file == 47;
for (length = last_component(file) - file;
prefix_length < length && file[length - 1] == 47; --length)
;
return length;
} | size_t dir_len(char const *file) {
size_t prefix_length = FILE_SYSTEM_PREFIX_LEN(file);
size_t length;
prefix_length +=
(prefix_length != 0
? (FILE_SYSTEM_DRIVE_PREFIX_CAN_BE_RELATIVE &&
ISSLASH(file[prefix_length]))
... | dir_len | augeas-1.12.0 | app-admin | O0/app-admin/augeas-1.12.0/libfa.so.1.5.3 | ida | O0 |
fa *expand_alphabet(fa *fa, int add_marker, char X, char Y) {
fa *faa;
state *p;
state *r;
state *q;
faa = fa_clone(fa);
if (!faa)
return 0;
if (mark_reachable(faa) < 0) {
error:
fa_free(faa);
return 0;
} else {
for (p = faa->initial; p; p = p->next) {
if ((*((_BYTE *)p + 16) & ... | static struct fa *expand_alphabet(struct fa *fa, int add_marker,
char X, char Y) {
int ret;
fa = fa_clone(fa);
if (fa == NULL)
return NULL;
F(mark_reachable(fa));
list_for_each(p, fa->initial) {
... | expand_alphabet | augeas-1.12.0 | app-admin | O0/app-admin/augeas-1.12.0/libfa.so.1.5.3 | ida | O0 |
state_set *fa_accept_states(fa *fa) {
state *s;
state_set *accept;
accept = state_set_init(-1, 0);
if (accept && mark_reachable(fa) >= 0) {
for (s = fa->initial; s; s = s->next) {
if ((*((_BYTE *)s + 16) & 4) != 0 && (*((_BYTE *)s + 16) & 1) != 0 &&
state_set_push(accept, s) < 0)
go... | static struct state_set *fa_accept_states(struct fa *fa) {
struct state_set *accept = state_set_init(-1, S_NONE);
int r;
E(accept == NULL);
r = mark_reachable(fa);
E(r < 0);
list_for_each(s, fa->initial) {
if (s->reachable && s->accept)
... | fa_accept_states | augeas-1.12.0 | app-admin | O0/app-admin/augeas-1.12.0/libfa.so.1.5.3 | ida | O0 |
int fa_ambig_example(fa *fa1, fa *fa2, char **upv, size_t *upv_len, char **pv,
char **v) {
char *v7;
char *v8;
char *v9;
int ret;
int i;
int ia;
int ib;
int r;
char *result;
char *s;
fa *mp;
fa *ms;
fa *sp_0;
fa *ss_0;
fa *a2f;
fa *b2;
size_t s_len;
size_t result... | int fa_ambig_example(struct fa *fa1, struct fa *fa2, char **upv,
size_t *upv_len, char **pv, char **v) {
static const char X = '\001';
static const char Y = '\002';
char *result = NULL, *s = NULL;
size_t result_len = 0;
int ret = -1, r... | fa_ambig_example | augeas-1.12.0 | app-admin | O0/app-admin/augeas-1.12.0/libfa.so.1.5.3 | ida | O0 |
int fa_as_regexp(fa *fa, char **regexp, size_t *regexp_len) {
re *re;
fa *faa;
int t1;
int t_0;
re *eps;
state *s;
state *s_0;
re *loop;
trans *t;
state *s1;
trans *t_1;
state *s_1;
trans *t_2;
state *fin;
state *ini;
re_str str;
unsigned long v21;
v21 = __readfsqword(0x28u);
eps ... | int fa_as_regexp(struct fa *fa, char **regexp, size_t *regexp_len) {
int r;
struct state *fin = NULL, *ini = NULL;
struct re *eps = NULL;
*regexp = NULL;
*regexp_len = 0;
fa = fa_clone(fa);
if (fa == NULL)
goto error;
... | fa_as_regexp | augeas-1.12.0 | app-admin | O0/app-admin/augeas-1.12.0/libfa.so.1.5.3 | ida | O0 |
fa *fa_clone(fa *fa) {
int i_0;
int to;
int i;
fa *result;
state *s;
trans *t;
state_set *set;
state *s_0;
state *sc;
state *toc;
state *q;
unsigned long v13;
v13 = __readfsqword(0x28u);
result = 0;
set = state_set_init(-1, 3);
if (fa && set && mem_alloc_n(&result, 0x10u, 1u) >= 0) {
... | static struct fa *fa_clone(struct fa *fa) {
struct fa *result = NULL;
struct state_set *set = state_set_init(-1, S_DATA | S_SORTED);
int r;
if (fa == NULL || set == NULL || ALLOC(result) < 0)
goto error;
result->deterministic = fa->deterministic;
... | fa_clone | augeas-1.12.0 | app-admin | O0/app-admin/augeas-1.12.0/libfa.so.1.5.3 | ida | O0 |
int fa_compile(const char *regexp, size_t size, fa **fa) {
re *re;
re_parse parse;
unsigned long v7;
v7 = __readfsqword(0x28u);
*fa = 0;
parse.rx = regexp;
parse.rend = ®exp[size];
parse.error = 0;
re = parse_regexp(&parse);
if (!re)
return parse.error;
*fa = fa_from_re(re);
if (re->ref ... | int fa_compile(const char *regexp, size_t size, struct fa **fa) {
struct re *re = NULL;
struct re_parse parse;
*fa = NULL;
parse.rx = regexp;
parse.rend = regexp + size;
parse.error = REG_NOERROR;
re = parse_regexp(&parse);
if (r... | fa_compile | augeas-1.12.0 | app-admin | O0/app-admin/augeas-1.12.0/libfa.so.1.5.3 | ida | O0 |
fa *fa_complement(fa *fa) {
fa *faa;
state *s;
faa = fa_clone(fa);
if (faa) {
if (determinize(faa, 0) >= 0 && totalize(faa) >= 0) {
for (s = faa->initial; s; s = s->next)
*((_BYTE *)s + 16) =
((*((_BYTE *)s + 16) & 1) == 0) | *((_BYTE *)s + 16) & 0xFE;
if (collect(faa) >= 0)... | struct fa *fa_complement(struct fa *fa) {
fa = fa_clone(fa);
E(fa == NULL);
F(determinize(fa, NULL));
F(totalize(fa));
list_for_each(s, fa->initial) s->accept = !s->accept;
F(collect(fa));
return fa;
error:
fa_free(fa);
... | fa_complement | augeas-1.12.0 | app-admin | O0/app-admin/augeas-1.12.0/libfa.so.1.5.3 | ida | O0 |
fa *fa_concat(fa *fa1, fa *fa2) {
fa *fa2a;
fa *fa1a;
fa1a = fa_clone(fa1);
fa2a = fa_clone(fa2);
if (fa1a && fa2a && concat_in_place(fa1a, &fa2a) >= 0 && collect(fa1a) >= 0)
return fa1a;
fa_free(fa1a);
fa_free(fa2a);
return 0;
} | struct fa *fa_concat(struct fa *fa1, struct fa *fa2) {
fa1 = fa_clone(fa1);
fa2 = fa_clone(fa2);
if (fa1 == NULL || fa2 == NULL)
goto error;
F(concat_in_place(fa1, &fa2));
F(collect(fa1));
return fa1;
error:
fa_free(... | fa_concat | augeas-1.12.0 | app-admin | O0/app-admin/augeas-1.12.0/libfa.so.1.5.3 | ida | O0 |
int fa_contains(fa *fa1, fa *fa2) {
int result;
int n1;
int b2;
int min1;
int max1;
int n2;
state_set *worklist;
state_set *visited;
void *v2;
state *p1;
state *p2;
trans *t1;
trans *t2;
unsigned long v16;
v16 = __readfsqword(0x28u);
result = 0;
worklist = 0;
visited = 0;
if (!fa1... | int fa_contains(struct fa *fa1, struct fa *fa2) {
int result = 0;
struct state_set *worklist = NULL;
struct state_set *visited = NULL;
if (fa1 == NULL || fa2 == NULL)
return -1;
if (fa1 == fa2)
return 1;
F(determinize(fa2, NU... | fa_contains | augeas-1.12.0 | app-admin | O0/app-admin/augeas-1.12.0/libfa.so.1.5.3 | ida | O0 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.