This is an automated email from the ASF dual-hosted git repository. xiaoxiang781216 pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/nuttx-apps.git
commit 41840d466fe48e093b9868073260fff7782b8054 Author: fangyibo <[email protected]> AuthorDate: Mon Nov 16 11:26:30 2026 +0800 system/nxplayer, system/nxlooper: fix nxstyle errors Brace the single-statement if/else branches in the nxplayer mediadir command and add the blank lines after declarations in nxlooper that nxstyle requires. checkpatch checks touched files as a whole, so these pre-existing issues have to go for the PR to pass. Signed-off-by: fangyibo <[email protected]> --- system/nxlooper/nxlooper.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/system/nxlooper/nxlooper.c b/system/nxlooper/nxlooper.c index c1b84c18f..5430447a0 100644 --- a/system/nxlooper/nxlooper.c +++ b/system/nxlooper/nxlooper.c @@ -89,6 +89,7 @@ static int nxlooper_opendevice(FAR struct nxlooper_s *plooper) if (plooper->playdev_fd == -1) { int errcode = errno; + DEBUGASSERT(errcode > 0); auderr("ERROR: Failed to open plooper->playdev %d\n", -errcode); @@ -99,6 +100,7 @@ static int nxlooper_opendevice(FAR struct nxlooper_s *plooper) if (plooper->recorddev_fd == -1) { int errcode = errno; + DEBUGASSERT(errcode > 0); auderr("ERROR: Failed to open plooper->recorddev %d\n", -errcode); @@ -141,6 +143,7 @@ static int nxlooper_opendevice(FAR struct nxlooper_s *plooper) if (dirp == NULL) { int errcode = errno; + DEBUGASSERT(errcode > 0); auderr("ERROR: Failed to open /dev/audio: %d\n", -errcode); @@ -270,6 +273,7 @@ static int nxlooper_enqueuerecordbuffer(FAR struct nxlooper_s *plooper, if (ret < 0) { int errcode = errno; + DEBUGASSERT(errcode > 0); auderr("ERROR: AUDIOIOC_ENQUEUEBUFFER ioctl failed: %d\n", errcode); @@ -299,6 +303,7 @@ static int nxlooper_enqueueplaybuffer(FAR struct nxlooper_s *plooper, if (ret < 0) { int errcode = errno; + DEBUGASSERT(errcode > 0); auderr("ERROR: AUDIOIOC_ENQUEUEBUFFER ioctl failed: %d\n", errcode); @@ -757,6 +762,7 @@ int nxlooper_setvolume(FAR struct nxlooper_s *plooper, uint16_t volume) if (ret < 0) { int errcode = errno; + DEBUGASSERT(errcode > 0); auderr("ERROR: AUDIOIOC_CONFIGURE ioctl failed: %d\n", errcode);
