(as originally declared in System V) to "char * const []", as was done in
1003.2 and subsequently propagated into XPG4.
From Andrew Cagney in PR lib/8930.
descriptors against -1 (as appropriate).
* add actual checks which to detect stuff that would trigger_DIAGASSERT(),
and attempt to return a sane error condition.
* knf some code
* remove some `register' decls.
the first two items result in the addition of code similar to the
following in various functions:
_DIAGASSERT(path != NULL)
#ifdef _DIAGNOSTIC
if (path == NULL) {
errno = EFAULT;
return (-1);
}
#endif
units of storage and returning a null pointer in System V mode; this was
broken by the `fix' in rev. 1.24. Also, as it is stated in ISO C that
such operation does not constitute an allocation failure, do not abort()
even if the `X' option is set.
Amusingly enough the SVID, Fourth Edition, specifies the `unique pointer'
return behaviour for this kind of allocation, so this is kind of mis-named.
(also from freebsd). comment out references to reallocf with .\"XXX"
for now. i also fixed some roff misuse as well.
replace calloc(3), free(3) and realloc(3) with links to malloc(3)
Make code ANSI/ISO C conformant. Formerly undefined constructs were used
making load/store architectures (like mips&alpha) fail whn compiled with
gcc -O2.
Tested on mips and i386 ok. Can someone with an alpha test this please?
* still needs an implementation-independent ("reentrant.h") method for
disabling cancellation,
* break a leg to leave realloc() `storage compaction' as was for non-reentrant
code,
* use of stdio in assertion code is unsafe.
delimiter as opposed to any string merely beginning with '-''-'; change to
match the standard. From Simon J. Gerraty <sjg@quick.com.au> in PR lib/6762.
installed using atexit() to be executed which is supposed to happen on
`normal termination' of the process only, whereas abort() is specifically
defined to cause `abnormal termination'.
random_mutex is locked, because
* a cancellation point may occur during fprintf(), and no cancellation handler
had been installed, and
* the XSH5 specifcation of these functions does not permit output to stderr.
Therefore, in initstate() and setstate(), return a null pointer if the supplied
state is not valid. This also fixes a bug in setstate() which caused corrupt
state information being used despite printing an error message.