mirror of
https://github.com/tuxbox-neutrino/libstb-hal.git
synced 2025-08-26 15:02:58 +02:00
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:
@@ -283,11 +283,11 @@ int32_t LinuxDvbBuffOpen(Context_t *context, char *type, int outfd, void *mtx)
|
||||
|
||||
if (!ret)
|
||||
{
|
||||
if (!strcmp("video", type) && -1 == videofd)
|
||||
if (!strcmp("video", type) && videofd == -1)
|
||||
{
|
||||
videofd = outfd;
|
||||
}
|
||||
else if (!strcmp("audio", type) && -1 == audiofd)
|
||||
else if (!strcmp("audio", type) && audiofd == -1)
|
||||
{
|
||||
audiofd = outfd;
|
||||
}
|
||||
|
@@ -53,7 +53,7 @@
|
||||
void FlushPipe(int pipefd)
|
||||
{
|
||||
char tmp;
|
||||
while (1 == read(pipefd, &tmp, 1));
|
||||
while (read(pipefd, &tmp, 1) == 1);
|
||||
}
|
||||
|
||||
ssize_t WriteExt(WriteV_t _call, int fd, void *data, size_t size)
|
||||
|
@@ -276,7 +276,7 @@ static int32_t writeData(void *_call)
|
||||
iov[2].iov_len = SubFrameLen;
|
||||
|
||||
//write the PCM data
|
||||
if (16 == pcmPrivateData->bits_per_coded_sample)
|
||||
if (pcmPrivateData->bits_per_coded_sample == 16)
|
||||
{
|
||||
for (n = 0; n < SubFrameLen; n += 2)
|
||||
{
|
||||
|
@@ -99,7 +99,7 @@ int InsertPesHeader(unsigned char *data, int size, unsigned char stream_id, unsi
|
||||
PutBits(&ld2, 0x1, 8); // Start Code
|
||||
PutBits(&ld2, stream_id, 8); // Stream_id = Audio Stream
|
||||
//4
|
||||
if (-1 == size)
|
||||
if (size == -1)
|
||||
{
|
||||
PutBits(&ld2, 0x0, 16);
|
||||
}
|
||||
|
Reference in New Issue
Block a user