Re: Replacing malloc/memset with calloc

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Aravind,

On Mon, Sep 28, 2020 at 12:12 AM Aravind Machiry <machiry@xxxxxxxxxxx> wrote:
>
> Hello,
>
> There are several places (at least in sdp.c) where `malloc` and
> memset(,0,) pattern Is used. All these can be replaced with calloc for
> efficiency.
>
> Is there any specific reason why malloc/memset is preferred?

It just old code that no one bother updating so far, we do have a
macro called malloc0 which does call calloc though.

-- 
Luiz Augusto von Dentz



[Index of Archives]     [Bluez Devel]     [Linux Wireless Networking]     [Linux Wireless Personal Area Networking]     [Linux ATH6KL]     [Linux USB Devel]     [Linux Media Drivers]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Big List of Linux Books]

  Powered by Linux