mirror of
https://gitlab.freedesktop.org/NetworkManager/NetworkManager.git
synced 2026-05-05 00:38:07 +02:00
shared: add NM_SWAP() macro
This commit is contained in:
parent
4fe46d9e20
commit
cec06138f1
1 changed files with 11 additions and 0 deletions
|
|
@ -757,6 +757,17 @@ NM_G_ERROR_MSG (GError *error)
|
|||
|
||||
/*****************************************************************************/
|
||||
|
||||
#define NM_SWAP(a, b) \
|
||||
G_STMT_START { \
|
||||
typeof (a) _tmp; \
|
||||
\
|
||||
_tmp = (a); \
|
||||
(a) = (b); \
|
||||
(b) = _tmp; \
|
||||
} G_STMT_END
|
||||
|
||||
/*****************************************************************************/
|
||||
|
||||
static inline gboolean
|
||||
_NM_IN_STRSET_streq (const char *x, const char *s)
|
||||
{
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue