summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--audio/aidl/default/include/effect-impl/EffectTypes.h60
1 files changed, 30 insertions, 30 deletions
diff --git a/audio/aidl/default/include/effect-impl/EffectTypes.h b/audio/aidl/default/include/effect-impl/EffectTypes.h
index 9740d6ee9c..66c0ff1cb4 100644
--- a/audio/aidl/default/include/effect-impl/EffectTypes.h
+++ b/audio/aidl/default/include/effect-impl/EffectTypes.h
@@ -75,49 +75,49 @@ inline std::ostream& operator<<(std::ostream& out, const RetCode& code) {
return out << "EnumError: " << code;
}
-#define RETURN_IF_ASTATUS_NOT_OK(status, message) \
- do { \
- const ::ndk::ScopedAStatus curr_status = (status); \
- if (!curr_status.isOk()) { \
- LOG(ERROR) << __func__ << ":" << __LINE__ \
- << "return with status: " << curr_status.getDescription() << (message); \
- return ndk::ScopedAStatus::fromExceptionCodeWithMessage( \
- curr_status.getExceptionCode(), (message)); \
- } \
+#define RETURN_IF_ASTATUS_NOT_OK(status, message) \
+ do { \
+ const ::ndk::ScopedAStatus curr_status = (status); \
+ if (!curr_status.isOk()) { \
+ LOG(ERROR) << __func__ << ": line" << __LINE__ \
+ << " return with status: " << curr_status.getDescription() << (message); \
+ return ndk::ScopedAStatus::fromExceptionCodeWithMessage( \
+ curr_status.getExceptionCode(), (message)); \
+ } \
} while (0)
#define RETURN_IF(expr, exception, message) \
do { \
if (expr) { \
- LOG(ERROR) << __func__ << ":" << __LINE__ << " return with expr " << #expr; \
+ LOG(ERROR) << __func__ << ": line" << __LINE__ << " return with expr " << #expr; \
return ndk::ScopedAStatus::fromExceptionCodeWithMessage((exception), (message)); \
} \
} while (0)
-#define RETURN_OK_IF(expr) \
- do { \
- if (expr) { \
- LOG(INFO) << __func__ << ":" << __LINE__ << " return with expr " << #expr; \
- return ndk::ScopedAStatus::ok(); \
- } \
+#define RETURN_OK_IF(expr) \
+ do { \
+ if (expr) { \
+ LOG(INFO) << __func__ << ": line" << __LINE__ << " return with expr " << #expr; \
+ return ndk::ScopedAStatus::ok(); \
+ } \
} while (0)
-#define RETURN_VALUE_IF(expr, ret, log) \
- do { \
- if (expr) { \
- LOG(ERROR) << __func__ << ":" << __LINE__ << " return with expr \"" << #expr \
- << "\":" << (log); \
- return ret; \
- } \
+#define RETURN_VALUE_IF(expr, ret, log) \
+ do { \
+ if (expr) { \
+ LOG(ERROR) << __func__ << ": line" << __LINE__ << " return with expr \"" << #expr \
+ << "\":" << (log); \
+ return ret; \
+ } \
} while (0)
-#define RETURN_IF_BINDER_EXCEPTION(functor) \
- { \
- binder_exception_t exception = functor; \
- if (EX_NONE != exception) { \
- LOG(ERROR) << #functor << ": failed with error " << exception; \
- return ndk::ScopedAStatus::fromExceptionCode(exception); \
- } \
+#define RETURN_IF_BINDER_EXCEPTION(functor) \
+ { \
+ binder_exception_t exception = functor; \
+ if (EX_NONE != exception) { \
+ LOG(ERROR) << #functor << ": failed with error " << exception; \
+ return ndk::ScopedAStatus::fromExceptionCode(exception); \
+ } \
}
/**