summaryrefslogtreecommitdiffstats
path: root/src/expect
diff options
context:
space:
mode:
Diffstat (limited to 'src/expect')
-rw-r--r--src/expect/api.c26
-rw-r--r--src/expect/build.c6
-rw-r--r--src/expect/parse.c14
-rw-r--r--src/expect/setter.c10
4 files changed, 28 insertions, 28 deletions
diff --git a/src/expect/api.c b/src/expect/api.c
index a1dbbff..8ff20e2 100644
--- a/src/expect/api.c
+++ b/src/expect/api.c
@@ -329,7 +329,7 @@ void nfexp_set_attr(struct nf_expect *exp,
*/
void nfexp_set_attr_u8(struct nf_expect *exp,
const enum nf_expect_attr type,
- u_int8_t value)
+ uint8_t value)
{
nfexp_set_attr(exp, type, &value);
}
@@ -342,7 +342,7 @@ void nfexp_set_attr_u8(struct nf_expect *exp,
*/
void nfexp_set_attr_u16(struct nf_expect *exp,
const enum nf_expect_attr type,
- u_int16_t value)
+ uint16_t value)
{
nfexp_set_attr(exp, type, &value);
}
@@ -355,7 +355,7 @@ void nfexp_set_attr_u16(struct nf_expect *exp,
*/
void nfexp_set_attr_u32(struct nf_expect *exp,
const enum nf_expect_attr type,
- u_int32_t value)
+ uint32_t value)
{
nfexp_set_attr(exp, type, &value);
}
@@ -395,10 +395,10 @@ const void *nfexp_get_attr(const struct nf_expect *exp,
* set, 0 is returned. In order to check if the attribute is set or not,
* use nfexp_attr_is_set.
*/
-u_int8_t nfexp_get_attr_u8(const struct nf_expect *exp,
+uint8_t nfexp_get_attr_u8(const struct nf_expect *exp,
const enum nf_expect_attr type)
{
- const u_int8_t *ret = nfexp_get_attr(exp, type);
+ const uint8_t *ret = nfexp_get_attr(exp, type);
return ret == NULL ? 0 : *ret;
}
@@ -411,10 +411,10 @@ u_int8_t nfexp_get_attr_u8(const struct nf_expect *exp,
* set, 0 is returned. In order to check if the attribute is set or not,
* use nfexp_attr_is_set.
*/
-u_int16_t nfexp_get_attr_u16(const struct nf_expect *exp,
+uint16_t nfexp_get_attr_u16(const struct nf_expect *exp,
const enum nf_expect_attr type)
{
- const u_int16_t *ret = nfexp_get_attr(exp, type);
+ const uint16_t *ret = nfexp_get_attr(exp, type);
return ret == NULL ? 0 : *ret;
}
@@ -427,10 +427,10 @@ u_int16_t nfexp_get_attr_u16(const struct nf_expect *exp,
* set, 0 is returned. In order to check if the attribute is set or not,
* use nfexp_attr_is_set.
*/
-u_int32_t nfexp_get_attr_u32(const struct nf_expect *exp,
+uint32_t nfexp_get_attr_u32(const struct nf_expect *exp,
const enum nf_expect_attr type)
{
- const u_int32_t *ret = nfexp_get_attr(exp, type);
+ const uint32_t *ret = nfexp_get_attr(exp, type);
return ret == NULL ? 0 : *ret;
}
@@ -504,8 +504,8 @@ int nfexp_attr_unset(struct nf_expect *exp,
int nfexp_build_expect(struct nfnl_subsys_handle *ssh,
void *req,
size_t size,
- u_int16_t type,
- u_int16_t flags,
+ uint16_t type,
+ uint16_t flags,
const struct nf_expect *exp)
{
assert(ssh != NULL);
@@ -521,7 +521,7 @@ __build_query_exp(struct nfnl_subsys_handle *ssh,
const void *data, void *buffer, unsigned int size)
{
struct nfnlhdr *req = buffer;
- const u_int8_t *family = data;
+ const uint8_t *family = data;
assert(ssh != NULL);
assert(data != NULL);
@@ -580,7 +580,7 @@ __build_query_exp(struct nfnl_subsys_handle *ssh,
* NFEXP_Q_FLUSH
* NFEXP_Q_DUMP
*
- * Pass a valid pointer to the protocol family (u_int8_t)
+ * Pass a valid pointer to the protocol family (uint8_t)
*
* On success, 0 is returned. On error, -1 is returned and errno is set
* appropiately.
diff --git a/src/expect/build.c b/src/expect/build.c
index d480fad..da59022 100644
--- a/src/expect/build.c
+++ b/src/expect/build.c
@@ -52,11 +52,11 @@ static void __build_expectfn(struct nfnlhdr *req,
int __build_expect(struct nfnl_subsys_handle *ssh,
struct nfnlhdr *req,
size_t size,
- u_int16_t type,
- u_int16_t flags,
+ uint16_t type,
+ uint16_t flags,
const struct nf_expect *exp)
{
- u_int8_t l3num;
+ uint8_t l3num;
if (test_bit(ATTR_ORIG_L3PROTO, exp->master.set))
l3num = exp->master.orig.l3protonum;
diff --git a/src/expect/parse.c b/src/expect/parse.c
index e71118b..9b944a6 100644
--- a/src/expect/parse.c
+++ b/src/expect/parse.c
@@ -11,8 +11,8 @@
int __parse_expect_message_type(const struct nlmsghdr *nlh)
{
- u_int16_t type = NFNL_MSG_TYPE(nlh->nlmsg_type);
- u_int16_t flags = nlh->nlmsg_flags;
+ uint16_t type = NFNL_MSG_TYPE(nlh->nlmsg_type);
+ uint16_t flags = nlh->nlmsg_flags;
int ret = NFCT_T_UNKNOWN;
if (type == IPCTNL_MSG_EXP_NEW) {
@@ -65,18 +65,18 @@ void __parse_expect(const struct nlmsghdr *nlh,
}
if (cda[CTA_EXPECT_TIMEOUT-1]) {
exp->timeout =
- ntohl(*(u_int32_t *)NFA_DATA(cda[CTA_EXPECT_TIMEOUT-1]));
+ ntohl(*(uint32_t *)NFA_DATA(cda[CTA_EXPECT_TIMEOUT-1]));
set_bit(ATTR_EXP_TIMEOUT, exp->set);
}
if (cda[CTA_EXPECT_ZONE-1]) {
exp->zone =
- ntohs(*(u_int16_t *)NFA_DATA(cda[CTA_EXPECT_ZONE-1]));
+ ntohs(*(uint16_t *)NFA_DATA(cda[CTA_EXPECT_ZONE-1]));
set_bit(ATTR_EXP_ZONE, exp->set);
}
if (cda[CTA_EXPECT_FLAGS-1]) {
exp->flags =
- ntohl(*(u_int32_t *)NFA_DATA(cda[CTA_EXPECT_FLAGS-1]));
+ ntohl(*(uint32_t *)NFA_DATA(cda[CTA_EXPECT_FLAGS-1]));
set_bit(ATTR_EXP_FLAGS, exp->set);
}
if (cda[CTA_EXPECT_HELP_NAME-1]) {
@@ -86,7 +86,7 @@ void __parse_expect(const struct nlmsghdr *nlh,
}
if (cda[CTA_EXPECT_CLASS-1]) {
exp->class =
- ntohl(*(u_int32_t *)NFA_DATA(cda[CTA_EXPECT_CLASS-1]));
+ ntohl(*(uint32_t *)NFA_DATA(cda[CTA_EXPECT_CLASS-1]));
set_bit(ATTR_EXP_CLASS, exp->set);
}
if (cda[CTA_EXPECT_NAT-1]) {
@@ -107,7 +107,7 @@ void __parse_expect(const struct nlmsghdr *nlh,
}
if (tb[CTA_EXPECT_NAT_DIR-1]) {
exp->nat_dir =
- ntohl(*((u_int32_t *)
+ ntohl(*((uint32_t *)
NFA_DATA(tb[CTA_EXPECT_NAT_DIR-1])));
set_bit(ATTR_EXP_NAT_DIR, exp->set);
}
diff --git a/src/expect/setter.c b/src/expect/setter.c
index 2cf29c2..18c925a 100644
--- a/src/expect/setter.c
+++ b/src/expect/setter.c
@@ -26,22 +26,22 @@ static void set_exp_attr_mask(struct nf_expect *exp, const void *value)
static void set_exp_attr_timeout(struct nf_expect *exp, const void *value)
{
- exp->timeout = *((u_int32_t *) value);
+ exp->timeout = *((uint32_t *) value);
}
static void set_exp_attr_zone(struct nf_expect *exp, const void *value)
{
- exp->zone = *((u_int16_t *) value);
+ exp->zone = *((uint16_t *) value);
}
static void set_exp_attr_flags(struct nf_expect *exp, const void *value)
{
- exp->flags = *((u_int32_t *) value);
+ exp->flags = *((uint32_t *) value);
}
static void set_exp_attr_class(struct nf_expect *exp, const void *value)
{
- exp->class = *((u_int32_t *) value);
+ exp->class = *((uint32_t *) value);
}
static void set_exp_attr_helper_name(struct nf_expect *exp, const void *value)
@@ -52,7 +52,7 @@ static void set_exp_attr_helper_name(struct nf_expect *exp, const void *value)
static void set_exp_attr_nat_dir(struct nf_expect *exp, const void *value)
{
- exp->nat_dir = *((u_int32_t *) value);
+ exp->nat_dir = *((uint32_t *) value);
}
static void set_exp_attr_nat_tuple(struct nf_expect *exp, const void *value)