mirror of
https://gitlab.freedesktop.org/NetworkManager/NetworkManager.git
synced 2025-12-28 00:30:09 +01:00
std-aux: add NM_IFNAMSIZE
This commit is contained in:
parent
6b28c2867b
commit
3fd656ed37
2 changed files with 10 additions and 0 deletions
|
|
@ -1367,6 +1367,12 @@ nm_ptr_to_uintptr(const void *p)
|
|||
|
||||
/*****************************************************************************/
|
||||
|
||||
/* IFNAMSIZ is both defined in <linux/if.h> and <net/if.h>. In the past, these
|
||||
* headers conflicted, so we cannot simply include either of them in a header-file.*/
|
||||
#define NM_IFNAMSIZ 16
|
||||
|
||||
/*****************************************************************************/
|
||||
|
||||
#define NM_AF_UNSPEC 0 /* AF_UNSPEC */
|
||||
#define NM_AF_INET 2 /* AF_INET */
|
||||
#define NM_AF_INET6 10 /* AF_INET6 */
|
||||
|
|
|
|||
|
|
@ -7,9 +7,13 @@
|
|||
#include <stdint.h>
|
||||
#include <assert.h>
|
||||
#include <limits.h>
|
||||
#include <net/if.h>
|
||||
|
||||
/*****************************************************************************/
|
||||
|
||||
NM_STATIC_ASSERT(NM_IFNAMSIZ == IFNAMSIZ);
|
||||
|
||||
/*****************************************************************************/
|
||||
size_t
|
||||
nm_utils_get_next_realloc_size(bool true_realloc, size_t requested)
|
||||
{
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue