Changeset ff2c0c1149028b5eab96e7e18e4b55b0e22a8d0d

Show
Ignore:
Timestamp:
04/12/05 16:43:01 (3 years ago)
Author:
Rémi Denis-Courmont <rem@videolan.org>
git-committer:
Rémi Denis-Courmont <rem@videolan.org> 1113316981 +0000
git-parent:

[a6cb8953d4bb5d5b75eeeb6fb7c9009591ee8431]

git-author:
Rémi Denis-Courmont <rem@videolan.org> 1113316981 +0000
Message:

Simplifying

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • modules/services_discovery/sap.c

    r8f46736 rff2c0c1  
    508508{ 
    509509    int     i; 
    510     uint8_t     *p_buffer; 
    511510    playlist_t  *p_playlist; 
    512511 
     
    515514    { 
    516515        int i_read; 
    517         p_buffer = (uint8_t *)malloc( MAX_SAP_BUFFER ); 
    518  
    519         if( !p_buffer ) 
    520         { 
    521             msg_Err( p_sd, "out of memory"); 
    522             p_sd->b_die = VLC_TRUE; 
    523             continue; 
    524         } 
     516    uint8_t p_buffer[MAX_SAP_BUFFER]; 
    525517 
    526518        i_read = net_Select( p_sd, p_sd->p_sys->pi_fd, NULL, 
     
    566558                msg_Warn( p_sd, "socket read error" ); 
    567559            } 
    568             free( p_buffer ); 
    569560            continue; 
    570561        } 
     
    574565        /* Parse the packet */ 
    575566        ParseSAP( p_sd, p_buffer, i_read ); 
    576  
    577         free( p_buffer ); 
    578567    } 
    579568}