Skip to content

Commit

Permalink
Merge pull request #75 from ittiam-systems/bug-70
Browse files Browse the repository at this point in the history
Bug 70
  • Loading branch information
mekya authored Jun 23, 2019
2 parents 730c5f8 + b0118cb commit 6047dc5
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions rtmp-client/src/main/cpp/librtmp/rtmp.c
Original file line number Diff line number Diff line change
Expand Up @@ -4998,6 +4998,7 @@ RTMP_Read(RTMP *r, char *buf, int size)
memcpy(mybuf, flvHeader, sizeof(flvHeader));
r->m_read.buf += sizeof(flvHeader);
r->m_read.buflen -= sizeof(flvHeader);
cnt += sizeof(flvHeader);

while (r->m_read.timestamp == 0)
{
Expand All @@ -5014,6 +5015,7 @@ RTMP_Read(RTMP *r, char *buf, int size)
if (r->m_read.buf < mybuf || r->m_read.buf > end) {
mybuf = realloc(mybuf, cnt + nRead);
memcpy(mybuf+cnt, r->m_read.buf, nRead);
free(r->m_read.buf);
r->m_read.buf = mybuf+cnt+nRead;
break;
}
Expand Down

0 comments on commit 6047dc5

Please sign in to comment.