• Cedric Roux's avatar
    rlc v2: some fixes for 'bugs' found by coverity scan · 78de8ad4
    Cedric Roux authored
    Minor fixes, doesn't change anything. Not sure these are 'bugs' either,
    but let's be polite with coverity scan...
    
    One thing was not changed.
    Coverity scan says:
    *** CID 357991:  Memory - illegal accesses  (USE_AFTER_FREE)
    /home/carabe/raphael/openairinterface5g/openair2/LAYER2/rlc_v2/rlc_entity_am.c: 507 in tx_list_remove_sn()
    501         } else {
    502           prev = cur;
    503           cur = cur->next;
    504         }
    505       }
    506
    >>>     CID 357991:  Memory - illegal accesses  (USE_AFTER_FREE)
    >>>     Using freed pointer "head.next".
    507       return head.next;
    508     }
    509
    510     void cleanup_sdu_list(rlc_entity_am_t *entity)
    511     {
    512       rlc_sdu_t head;
    
    But as far as I understand, there is no problem. We don't access
    head.next at all if it has been freed. Or is there some aliasing
    going on there (pointer aliasing)? I doubt it. False positive?
    78de8ad4
rlc_oai_api.c 30.9 KB