mirror of
https://github.com/libretro/RetroArch
synced 2025-04-01 04:20:27 +00:00
(Apple) Style nits
This commit is contained in:
parent
e836691a20
commit
4bc43fae53
@ -71,13 +71,16 @@ static bool CopyModel(char** model, uint32_t *majorRev, uint32_t *minorRev)
|
||||
}
|
||||
|
||||
modelLen = strcspn(machineModel, "0123456789");
|
||||
|
||||
if (modelLen == 0)
|
||||
{
|
||||
RARCH_ERR("CopyModel: Could not find machine model name\n");
|
||||
success = false;
|
||||
goto exit;
|
||||
}
|
||||
|
||||
*model = strndup(machineModel, modelLen);
|
||||
|
||||
if (*model == NULL)
|
||||
{
|
||||
RARCH_ERR("CopyModel: Could not find machine model name\n");
|
||||
@ -88,6 +91,7 @@ static bool CopyModel(char** model, uint32_t *majorRev, uint32_t *minorRev)
|
||||
*majorRev = 0;
|
||||
*minorRev = 0;
|
||||
revStr = strpbrk(machineModel, "0123456789");
|
||||
|
||||
if (!revStr)
|
||||
{
|
||||
RARCH_ERR("CopyModel: Could not find machine version number, inferred value is 0,0\n");
|
||||
@ -96,6 +100,7 @@ static bool CopyModel(char** model, uint32_t *majorRev, uint32_t *minorRev)
|
||||
}
|
||||
|
||||
count = sscanf(revStr, "%d,%d", majorRev, minorRev);
|
||||
|
||||
if (count < 2)
|
||||
{
|
||||
RARCH_ERR("CopyModel: Could not find machine version number\n");
|
||||
|
Loading…
x
Reference in New Issue
Block a user