mirror of
https://gitlab.rtems.org/rtems/rtos/rtems.git
synced 2025-12-05 15:15:44 +00:00
Patch from D. V. Henkel-Wallace <gumby@zembu.com> to make macro nest properly in conditionals
This commit is contained in:
@@ -253,10 +253,12 @@ struct route_cb {
|
||||
|
||||
#ifdef KERNEL
|
||||
#define RTFREE(rt) \
|
||||
if ((rt)->rt_refcnt <= 1) \
|
||||
do { \
|
||||
if ((rt)->rt_refcnt <= 1) \
|
||||
rtfree(rt); \
|
||||
else \
|
||||
(rt)->rt_refcnt--;
|
||||
else \
|
||||
(rt)->rt_refcnt--; \
|
||||
} while (0)
|
||||
|
||||
extern struct route_cb route_cb;
|
||||
extern struct rtstat rtstat;
|
||||
|
||||
@@ -253,10 +253,12 @@ struct route_cb {
|
||||
|
||||
#ifdef KERNEL
|
||||
#define RTFREE(rt) \
|
||||
if ((rt)->rt_refcnt <= 1) \
|
||||
do { \
|
||||
if ((rt)->rt_refcnt <= 1) \
|
||||
rtfree(rt); \
|
||||
else \
|
||||
(rt)->rt_refcnt--;
|
||||
else \
|
||||
(rt)->rt_refcnt--; \
|
||||
} while (0)
|
||||
|
||||
extern struct route_cb route_cb;
|
||||
extern struct rtstat rtstat;
|
||||
|
||||
@@ -253,10 +253,12 @@ struct route_cb {
|
||||
|
||||
#ifdef KERNEL
|
||||
#define RTFREE(rt) \
|
||||
if ((rt)->rt_refcnt <= 1) \
|
||||
do { \
|
||||
if ((rt)->rt_refcnt <= 1) \
|
||||
rtfree(rt); \
|
||||
else \
|
||||
(rt)->rt_refcnt--;
|
||||
else \
|
||||
(rt)->rt_refcnt--; \
|
||||
} while (0)
|
||||
|
||||
extern struct route_cb route_cb;
|
||||
extern struct rtstat rtstat;
|
||||
|
||||
@@ -253,10 +253,12 @@ struct route_cb {
|
||||
|
||||
#ifdef KERNEL
|
||||
#define RTFREE(rt) \
|
||||
if ((rt)->rt_refcnt <= 1) \
|
||||
do { \
|
||||
if ((rt)->rt_refcnt <= 1) \
|
||||
rtfree(rt); \
|
||||
else \
|
||||
(rt)->rt_refcnt--;
|
||||
else \
|
||||
(rt)->rt_refcnt--; \
|
||||
} while (0)
|
||||
|
||||
extern struct route_cb route_cb;
|
||||
extern struct rtstat rtstat;
|
||||
|
||||
Reference in New Issue
Block a user