You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@mynewt.apache.org by ja...@apache.org on 2023/02/08 15:12:26 UTC
[mynewt-nimble] 02/02: porting: Fix SYSINIT_PANIC_ASSERT_MSG refinition warning
This is an automated email from the ASF dual-hosted git repository.
janc pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/mynewt-nimble.git
commit 69c0d323a9e85d19d523c67c7addaa9bee778dac
Author: Xiang Xiao <xi...@xiaomi.com>
AuthorDate: Mon Feb 6 16:51:03 2023 +0800
porting: Fix SYSINIT_PANIC_ASSERT_MSG refinition warning
porting/npl/nuttx/include/nimble/nimble_npl_os.h:40: warning: "SYSINIT_PANIC_ASSERT_MSG" redefined
40 | #define SYSINIT_PANIC_ASSERT_MSG(rc, msg) do \
|
nimble/host/services/tps/src/ble_svc_tps.c:22:
porting/nimble/include/sysinit/sysinit.h:32: note: this is the location of the previous definition
32 | #define SYSINIT_PANIC_ASSERT_MSG(rc, msg) assert(rc)
|
Signed-off-by: Xiang Xiao <xi...@xiaomi.com>
---
porting/npl/linux/include/nimble/nimble_npl_os.h | 7 -------
porting/npl/nuttx/include/nimble/nimble_npl_os.h | 7 -------
2 files changed, 14 deletions(-)
diff --git a/porting/npl/linux/include/nimble/nimble_npl_os.h b/porting/npl/linux/include/nimble/nimble_npl_os.h
index 585d3785..17e61b22 100644
--- a/porting/npl/linux/include/nimble/nimble_npl_os.h
+++ b/porting/npl/linux/include/nimble/nimble_npl_os.h
@@ -37,13 +37,6 @@ extern "C" {
#define SYSINIT_PANIC_MSG(msg) __assert_fail(msg, __FILE__, __LINE__, __func__)
-#define SYSINIT_PANIC_ASSERT_MSG(rc, msg) do \
-{ \
- if (!(rc)) { \
- SYSINIT_PANIC_MSG(msg); \
- } \
-} while (0)
-
#ifdef __cplusplus
}
#endif
diff --git a/porting/npl/nuttx/include/nimble/nimble_npl_os.h b/porting/npl/nuttx/include/nimble/nimble_npl_os.h
index 0f765f5a..a2fcbc42 100644
--- a/porting/npl/nuttx/include/nimble/nimble_npl_os.h
+++ b/porting/npl/nuttx/include/nimble/nimble_npl_os.h
@@ -37,13 +37,6 @@ extern "C" {
#define SYSINIT_PANIC_MSG(msg) { fprintf(stderr, "%s\n", msg); abort(); }
-#define SYSINIT_PANIC_ASSERT_MSG(rc, msg) do \
-{ \
- if (!(rc)) { \
- SYSINIT_PANIC_MSG(msg); \
- } \
-} while (0)
-
#ifdef __cplusplus
}
#endif