From: Pablo Neira Ayuso <pablo@netfilter.org>
To: Nathan McSween <nwmcsween@gmail.com>
Cc: netfilter-devel@vger.kernel.org
Subject: Re: [PATCH] Use stdlib uint* instead of u_int*
Date: Wed, 8 Apr 2015 19:54:04 +0200 [thread overview]
Message-ID: <20150408175404.GA5146@salvia> (raw)
In-Reply-To: <1428098686-17843-1-git-send-email-nwmcsween@gmail.com>
On Fri, Apr 03, 2015 at 10:04:46PM +0000, Nathan McSween wrote:
[...]
> diff --git a/include/libnfnetlink/linux_nfnetlink.h b/include/libnfnetlink/linux_nfnetlink.h
> index 76a8550..7b843c6 100644
> --- a/include/libnfnetlink/linux_nfnetlink.h
> +++ b/include/libnfnetlink/linux_nfnetlink.h
> @@ -1,5 +1,6 @@
> #ifndef _NFNETLINK_H
> #define _NFNETLINK_H
> +#include <stdint.h>
> #include <linux/types.h>
> #include <libnfnetlink/linux_nfnetlink_compat.h>
>
> @@ -25,9 +26,9 @@ enum nfnetlink_groups {
> /* General form of address family dependent message.
> */
> struct nfgenmsg {
> - u_int8_t nfgen_family; /* AF_xxx */
> - u_int8_t version; /* nfnetlink version */
> - u_int16_t res_id; /* resource id */
> + uint8_t nfgen_family; /* AF_xxx */
> + uint8_t version; /* nfnetlink version */
> + uint16_t res_id; /* resource id */
This header file is a copy of what you can get from the Linux kernel
source tree. We shouldn't change this, instead you can refresh it.
> };
>
> #define NFNETLINK_V0 0
> @@ -59,7 +60,7 @@ struct nfnl_callback
> int (*call)(struct sock *nl, struct sk_buff *skb,
> struct nlmsghdr *nlh, struct nlattr *cda[]);
> const struct nla_policy *policy; /* netlink attribute policy */
> - const u_int16_t attr_count; /* number of nlattr's */
> + const uint16_t attr_count; /* number of nlattr's */
> };
>
> struct nfnetlink_subsystem
> @@ -76,7 +77,7 @@ extern int nfnetlink_subsys_unregister(const struct nfnetlink_subsystem *n);
> extern int nfnetlink_has_listeners(unsigned int group);
> extern int nfnetlink_send(struct sk_buff *skb, u32 pid, unsigned group,
> int echo);
> -extern int nfnetlink_unicast(struct sk_buff *skb, u_int32_t pid, int flags);
> +extern int nfnetlink_unicast(struct sk_buff *skb, uint32_t pid, int flags);
>
> #define MODULE_ALIAS_NFNL_SUBSYS(subsys) \
> MODULE_ALIAS("nfnetlink-subsys-" __stringify(subsys))
> diff --git a/include/libnfnetlink/linux_nfnetlink_compat.h b/include/libnfnetlink/linux_nfnetlink_compat.h
> index e145176..cd094fc 100644
> --- a/include/libnfnetlink/linux_nfnetlink_compat.h
> +++ b/include/libnfnetlink/linux_nfnetlink_compat.h
Same thing with this file.
next prev parent reply other threads:[~2015-04-08 17:49 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-04-03 22:04 [PATCH] Use stdlib uint* instead of u_int* Nathan McSween
2015-04-08 17:54 ` Pablo Neira Ayuso [this message]
-- strict thread matches above, loose matches on Subject: below --
2015-03-16 21:07 Nathan McSween
2015-03-16 21:07 ` Nathan McSween
2015-03-17 16:08 ` Pablo Neira Ayuso
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20150408175404.GA5146@salvia \
--to=pablo@netfilter.org \
--cc=netfilter-devel@vger.kernel.org \
--cc=nwmcsween@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.