Costmetic changes

This commit is contained in:
Gregory Nutt 2014-08-05 10:04:03 -06:00
parent 24d5b6b7f9
commit 2e5f4f160b

View File

@ -198,34 +198,33 @@ static int nxplayer_cmd_play(FAR struct nxplayer_s *pPlayer, char* parg)
* -ENOENT The media file was not found
*/
if (ret == -ENODEV)
switch (-ret)
{
printf("No suitable Audio Device found\n");
case OK:
break;
case ENODEV:
printf("No suitable Audio Device found\n");
break;
case EBUSY:
printf("Audio device busy\n");
break;
case ENOENT:
printf("File %s not found\n", parg);
break;
case ENOSYS:
printf("Unknown audio format\n");
break;
default:
printf("Error playing file: %d\n", -ret);
break;
}
else if (ret == -EBUSY)
{
printf("Audio device busy\n");
}
else if (ret == -ENOENT)
{
printf("File %s not found\n", parg);
}
else if (ret == -ENOSYS)
{
printf("Unknown audio format\n");
}
if (ret < 0)
{
return ret;
}
/* File playing successfully */
return OK;
return ret;
}
/****************************************************************************