Re: How to check whether malloc has allocated memory properly in caseif malloc(0) can return valid p

Discussion in 'C Programming' started by Gene, Dec 20, 2010.

  1. Gene

    Gene Guest

    Most allocators need a small header block for each allocation. So you're allocating headers even though they're associated with zero bytes available to the user.
    Gene, Dec 20, 2010
    #1
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Curt_C [MVP]
    Replies:
    1
    Views:
    522
  2. Replies:
    5
    Views:
    617
    Matt Wharton
    Dec 9, 2004
  3. Peter
    Replies:
    34
    Views:
    1,937
    Richard Tobin
    Oct 22, 2004
  4. Shivanand Kadwadkar
    Replies:
    83
    Views:
    4,772
    Keith Thompson
    Jan 8, 2011
  5. mark4asp
    Replies:
    5
    Views:
    170
    Zenobia
    Jul 7, 2004
Loading...

Share This Page