From 5dd915ee8aab32d5fce4ad47144fab3ad3063064 Mon Sep 17 00:00:00 2001 From: Alex Szpakowski Date: Tue, 25 Oct 2016 19:56:47 -0300 Subject: [PATCH] whitespace and formatting cleanup --HG-- branch : minor --- src/modules/sound/wrap_Decoder.cpp | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/src/modules/sound/wrap_Decoder.cpp b/src/modules/sound/wrap_Decoder.cpp index 97bb31f61..e9039f713 100644 --- a/src/modules/sound/wrap_Decoder.cpp +++ b/src/modules/sound/wrap_Decoder.cpp @@ -68,14 +68,16 @@ int w_Decoder_decode(lua_State *L) int decoded = t->decode(); if (decoded > 0) - luax_catchexcept(L, [&](){ - SoundData *s = instance()->newSoundData(t->getBuffer(), - decoded / (t->getBitDepth() / 8 * t->getChannels()), - t->getSampleRate(), t->getBitDepth(), t->getChannels()); + { + luax_catchexcept(L, [&]() { + SoundData *s = instance()->newSoundData(t->getBuffer(), + decoded / (t->getBitDepth() / 8 * t->getChannels()), + t->getSampleRate(), t->getBitDepth(), t->getChannels()); - luax_pushtype(L, SOUND_SOUND_DATA_ID, s); - s->release(); - }); + luax_pushtype(L, SOUND_SOUND_DATA_ID, s); + s->release(); + }); + } else lua_pushnil(L); return 1;