Re: Is realloc(3) permitted to fail when shrinking a block?

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

 



* 孙世龙 sunshilong via Gcc-help:

> As the subject, I couldn't find any positive or negative statements
> about this matter in the Linux Programmer's Manual.
>
> Could somebody shed some light on this matter?

As a quality-of-implementation issue, I would not expect realloc to
fail when shrinking a block.  As a fallback, it can always keep the
block in its original size, not changing anything.

The C standard does not require that reducing the size cannot lead to
failure.




[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux