3 ms·
"the case of alloca'ing 0 bytes. I __could__ see an argument for expecting that to be always null" ??? I would expect that it always succeeds. Rationale: if, a
by Someone 15y ago
"the case of alloca'ing 0 bytes. I __could__ see an argument for expecting that to be always null"
??? I would expect that it always succeeds. Rationale: if, at some time and place, alloca(n) succeeds, I expect that any alloca asking for less space would succeed, too.
- deleted 15y ago[deleted]
- dextorious 15y agoso alloca(-1) would succeed too, right?
- FooBarWidget 15y agoNo. According to the OS X and Linux man pages 'size' has type 'size_t'. It is undefined whether size_t is signed.
- Someone 15y agoalloca takes a sixe_t. I think size_t is unsigned. http://stackoverflow.com/questions/1089176/is-size-t-always-unsigned http://stackoverflow.com/questions/1089176/is-size-t-always-... seems to agree with that (correction welcome)