[RFC PATCH v2] net/memif: change socket listener owner uid/gid
Stephen Hemminger
stephen at networkplumber.org
Wed Nov 16 18:04:46 CET 2022
On Wed, 16 Nov 2022 13:09:20 +0000
Junxiao Shi <git at mail1.yoursunny.com> wrote:
> +static int
> +memif_set_owner(const char *key, const char *value, void *extra_args)
> +{
> + static_assert(sizeof(uid_t) == sizeof(uint32_t), "");
> + static_assert(sizeof(gid_t) == sizeof(uint32_t), "");
Use RTE_ASSERT() for these
> + uint32_t *id = (uint32_t *)extra_args;
> +
> + char *end = NULL;
> + unsigned long val = strtoul(value, &end, 10);
The DPDK style inherited from Linux kernel is to have blank line
after declarations.
More information about the dev
mailing list