Commit 38f300b1 authored by Jean-Paul Saman's avatar Jean-Paul Saman

Fix compiler warnings related to wrong datatypes.

parent c696a407
......@@ -225,7 +225,7 @@ static int Open( vlc_object_t *p_this )
p_sys->p_header = block_New( p_access, 4096 );
p_sys->p_header->i_buffer =
rmff_dump_header( h, p_sys->p_header->p_buffer, 1024 );
rmff_dump_header( h, (char *)p_sys->p_header->p_buffer, 1024 );
rmff_free_header( h );
}
else
......
......@@ -210,8 +210,8 @@ static void call_hash (char *key, char *challenge, int len) {
uint8_t *ptr1, *ptr2;
uint32_t a, b, c, d, tmp;
ptr1=(key+16);
ptr2=(key+20);
ptr1=(uint8_t*)(key+16);
ptr2=(uint8_t*)(key+20);
a = LE_32(ptr1);
b = (a >> 3) & 0x3f;
......@@ -338,7 +338,7 @@ void real_calc_response_and_checksum (char *response, char *chksum, char *challe
if (xor_table != NULL)
{
table_len = strlen(xor_table);
table_len = strlen((char *)xor_table);
if (table_len > 56) table_len=56;
......@@ -597,8 +597,8 @@ int real_get_rdt_chunk(rtsp_client_t *rtsp_session, rmff_pheader_t *ph,
unsigned char **buffer) {
int n;
rmff_dump_pheader(ph, *buffer);
n=rtsp_read_data(rtsp_session, *buffer + 12, ph->length - 12);
rmff_dump_pheader(ph, (char*)*buffer);
n=rtsp_read_data(rtsp_session, (uint8_t*)(*buffer + 12), ph->length - 12);
return (n <= 0) ? 0 : n+12;
}
......@@ -670,7 +670,7 @@ rmff_header_t *real_setup_and_get_header(rtsp_client_t *rtsp_session, int bandw
description = (char*)malloc(sizeof(char)*(size+1));
if( !description )
goto error;
if( rtsp_read_data(rtsp_session, description, size) <= 0)
if( rtsp_read_data(rtsp_session, (uint8_t*)description, size) <= 0)
goto error;
description[size]=0;
fprintf(stderr, "%s", description);
......
......@@ -89,7 +89,7 @@ static char *rtsp_get( rtsp_client_t *rtsp )
char *psz_buffer = malloc( BUF_SIZE );
char *psz_string = NULL;
if( rtsp->pf_read_line( rtsp->p_userdata, psz_buffer, (unsigned int)BUF_SIZE ) >= 0 )
if( rtsp->pf_read_line( rtsp->p_userdata, (uint8_t*)psz_buffer, (unsigned int)BUF_SIZE ) >= 0 )
{
//printf( "<< '%s'\n", psz_buffer );
psz_string = strdup( psz_buffer );
......@@ -114,7 +114,7 @@ static int rtsp_put( rtsp_client_t *rtsp, const char *psz_string )
psz_buffer[i_buffer] = '\r'; psz_buffer[i_buffer+1] = '\n';
psz_buffer[i_buffer+2] = 0;
i_ret = rtsp->pf_write( rtsp->p_userdata, psz_buffer, i_buffer + 2 );
i_ret = rtsp->pf_write( rtsp->p_userdata, (uint8_t*)psz_buffer, i_buffer + 2 );
free( psz_buffer );
return i_ret;
......@@ -393,13 +393,13 @@ int rtsp_request_tearoff( rtsp_client_t *rtsp, const char *what )
* read opaque data from stream
*/
int rtsp_read_data( rtsp_client_t *rtsp, char *buffer, unsigned int size )
int rtsp_read_data( rtsp_client_t *rtsp, uint8_t *buffer, unsigned int size )
{
int i, seq;
if( size >= 4 )
{
i = rtsp->pf_read( rtsp->p_userdata, buffer, (unsigned int) 4 );
i = rtsp->pf_read( rtsp->p_userdata, (uint8_t*)buffer, (unsigned int) 4 );
if( i < 4 ) return i;
if( buffer[0]=='S' && buffer[1]=='E' && buffer[2]=='T' &&
......
......@@ -58,7 +58,7 @@ int rtsp_request_tearoff( rtsp_client_t *, const char *what );
int rtsp_send_ok( rtsp_client_t * );
int rtsp_read_data( rtsp_client_t *, char *buffer, unsigned int size );
int rtsp_read_data( rtsp_client_t *, uint8_t *buffer, unsigned int size );
char* rtsp_search_answers( rtsp_client_t *, const char *tag );
void rtsp_free_answers( rtsp_client_t * );
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment