Supplement to "libeplayer3: Standardize comparison order and improve code readability"

Origin commit data
------------------
Commit: 0737aa3ba6
Author: vanhofen <vanhofen@gmx.de>
Date: 2024-03-25 (Mon, 25 Mar 2024)

Origin message was:
------------------
- addition to "small fix"

------------------
No further description and justification available within origin commit message!

------------------
This commit was generated by Migit
This commit is contained in:
vanhofen
2024-03-25 06:37:01 +01:00
committed by Thilo Graf
parent 73536563da
commit 900c92a67e
7 changed files with 16 additions and 16 deletions

View File

@@ -573,7 +573,7 @@ void cPlayback::FindAllPids(uint16_t *apids, unsigned short *ac3flags, uint16_t
{
int _pid;
char _lang[strlen(TrackList[i])];
if (2 == sscanf(TrackList[i], "%d %s\n", &_pid, _lang))
if (sscanf(TrackList[i], "%d %s\n", &_pid, _lang) == 2)
{
apids[j] = _pid;
// atUnknown, atMPEG, atMP3, atAC3, atDTS, atAAC, atPCM, atOGG, atFLAC
@@ -639,7 +639,7 @@ void cPlayback::FindAllSubtitlePids(int *pids, unsigned int *numpids, std::strin
{
int _pid;
char _lang[strlen(TrackList[i])];
if (2 == sscanf(TrackList[i], "%d %s\n", &_pid, _lang))
if (sscanf(TrackList[i], "%d %s\n", &_pid, _lang) == 2)
{
pids[j] = _pid;
language[j] = std::string(_lang);