zkStdlib.h is a portable wrapper for the Standard C header <stdlib.h>. It is part of the libzk library because there are parts of the Zero Knowledge code base that assume it contains functionality beyond that provided by Standard C, namely POSIX or platform-specific features.
Type | Description |
---|---|
div_t, a struct with members: | |
int quot |
|
int rem |
|
ldiv_t, a struct with members: | |
long int quot |
|
long int rem |
abort |
abs |
atexit |
atof |
atoi |
atol |
bsearch |
div |
exit |
labs |
ldiv |
qsort |
rand |
srand |
strtod |
strtol |
strtoul |
Don't Call This | Instead, Call This | Reason |
---|---|---|
calloc | zkCalloc | Standard C doesn't define calloc as setting errno. |
free | zkFree | For consistency with zkCalloc, zkMalloc, and zkRealloc. |
malloc | zkMalloc | Standard C doesn't define malloc as setting errno. |
realloc | zkRealloc | Standard C doesn't define realloc as setting errno. |