summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorEmil Velikov <[email protected]>2017-09-07 17:03:51 +0100
committerEmil Velikov <[email protected]>2017-09-19 19:08:34 +0100
commitcaf7fb627dae6b49830a11b85952815e0fd096db (patch)
treeec9dfc33b6cfd0568212d0b060df39a1fc30a793
parentb94344f1c70484d4ee59bb8765021a81fd54b366 (diff)
egl: remove unneeded braces around since line if statements
Signed-off-by: Emil Velikov <[email protected]> Reviewed-by: Eric Engestrom <[email protected]>
-rw-r--r--src/egl/main/eglcurrent.c14
1 files changed, 5 insertions, 9 deletions
diff --git a/src/egl/main/eglcurrent.c b/src/egl/main/eglcurrent.c
index db42b45309d..7af3011b757 100644
--- a/src/egl/main/eglcurrent.c
+++ b/src/egl/main/eglcurrent.c
@@ -281,11 +281,10 @@ _eglError(EGLint errCode, const char *msg)
{
if (errCode != EGL_SUCCESS) {
EGLint type;
- if (errCode == EGL_BAD_ALLOC) {
+ if (errCode == EGL_BAD_ALLOC)
type = EGL_DEBUG_MSG_CRITICAL_KHR;
- } else {
+ else
type = EGL_DEBUG_MSG_ERROR_KHR;
- }
_eglDebugReport(errCode, NULL, type, msg);
} else
@@ -306,9 +305,8 @@ _eglDebugReport(EGLenum error, const char *funcName,
funcName = thr->CurrentFuncName;
mtx_lock(_eglGlobal.Mutex);
- if (_eglGlobal.debugTypesEnabled & DebugBitFromType(type)) {
+ if (_eglGlobal.debugTypesEnabled & DebugBitFromType(type))
callback = _eglGlobal.debugCallback;
- }
mtx_unlock(_eglGlobal.Mutex);
@@ -317,9 +315,8 @@ _eglDebugReport(EGLenum error, const char *funcName,
if (message != NULL) {
va_start(args, message);
- if (vasprintf(&buf, message, args) < 0) {
+ if (vasprintf(&buf, message, args) < 0)
buf = NULL;
- }
va_end(args);
}
@@ -327,7 +324,6 @@ _eglDebugReport(EGLenum error, const char *funcName,
free(buf);
}
- if (type == EGL_DEBUG_MSG_CRITICAL_KHR || type == EGL_DEBUG_MSG_ERROR_KHR) {
+ if (type == EGL_DEBUG_MSG_CRITICAL_KHR || type == EGL_DEBUG_MSG_ERROR_KHR)
_eglInternalError(error, funcName);
- }
}