aboutsummaryrefslogtreecommitdiffstats
path: root/al/event.cpp
diff options
context:
space:
mode:
authorChris Robinson <[email protected]>2022-12-24 02:42:09 -0800
committerChris Robinson <[email protected]>2022-12-24 02:42:09 -0800
commit4fe6eba8c79a4c9cad91d6f6835506cde96a48c4 (patch)
tree4f57bbdf4e5bdea34a4d0030ed8ad1bc876041fd /al/event.cpp
parentf177f62e6737fff413361fae89db728c7e3a0cf9 (diff)
Avoid using a macro to set a context error and return
Diffstat (limited to 'al/event.cpp')
-rw-r--r--al/event.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/al/event.cpp b/al/event.cpp
index 19509d2f..2aceba3a 100644
--- a/al/event.cpp
+++ b/al/event.cpp
@@ -154,7 +154,7 @@ START_API_FUNC
if(count < 0) context->setError(AL_INVALID_VALUE, "Controlling %d events", count);
if(count <= 0) return;
- if(!types) SETERR_RETURN(context, AL_INVALID_VALUE,, "NULL pointer");
+ if(!types) return context->setError(AL_INVALID_VALUE, "NULL pointer");
ContextBase::AsyncEventBitset flags{};
const ALenum *types_end = types+count;
@@ -173,7 +173,7 @@ START_API_FUNC
}
);
if(bad_type != types_end)
- SETERR_RETURN(context, AL_INVALID_ENUM,, "Invalid event type 0x%04x", *bad_type);
+ return context->setError(AL_INVALID_ENUM, "Invalid event type 0x%04x", *bad_type);
if(enable)
{