MT#57440 in `RTMP_ReadPacket()` variable 'didAlloc' set but not used

Just removal of a few unsed variables:

     rtmp.c: In function 'RTMP_ReadPacket':
     rtmp.c:2854:7: warning: variable 'didAlloc' set but not used [-Wunused-but-set-variable]
      2854 |   int didAlloc = FALSE;
           |       ^~~~~~~~

and this:

     rtmp.c:1393:35: warning: 'av_record' defined but not used [-Wunused-const-variable=]
      1393 | #define SAVC(x) static const AVal av_##x = AVC(#x)
           |                                   ^~~
     rtmp.c:1706:1: note: in expansion of macro 'SAVC'
      1706 | SAVC(record);
           | ^~~~

Change-Id: I8a2bc2c415b44c99b6d881fb7118475f4020c713
mr11.4.1
Donat Zenichev 3 years ago
parent ff4a390bca
commit 0e1bd8891b

@ -1703,7 +1703,6 @@ SendFCUnpublish(RTMP *r)
SAVC(publish);
SAVC(live);
SAVC(record);
static int
SendPublish(RTMP *r)
@ -2851,7 +2850,6 @@ int RTMP_ReadPacket(RTMP *r, RTMPPacket *packet)
uint8_t hbuf[RTMP_MAX_HEADER_SIZE] = { 0 };
unsigned char *header = hbuf;
int nSize, hSize, nToRead, nChunk;
int didAlloc = FALSE;
RTMP_Log(RTMP_LOGDEBUG2, "%s: fd=%d", __FUNCTION__, r->m_sb.sb_socket);
@ -2959,7 +2957,6 @@ int RTMP_ReadPacket(RTMP *r, RTMPPacket *packet)
RTMP_Log(RTMP_LOGDEBUG, "%s, failed to allocate packet", __FUNCTION__);
return FALSE;
}
didAlloc = TRUE;
packet->m_headerType = (hbuf[0] & 0xc0) >> 6;
}

Loading…
Cancel
Save