Next: Networking and other low level functions, Previous: svz_address_t, Up: Embedding API [Contents][Index]
Within this section you will find some miscellaneous functionality and left overs of the C API.
Print a message to the log system. level specifies the prefix.
Set the file stream file to the log file all messages
are printed to. Can also be stdout
or stderr
.
Dump buffer with the length len to the file stream out. Display description action along with origin and size info first, followed by the hexadecimal text representation. Stop output at either max or len (if max is zero) bytes. from is a numerical identifier of the buffers creator.
Convert an unsigned integer to its decimal string representation, returning a pointer to an internal buffer. (You should copy the result.)
Convert string str in decimal format to an unsigned integer. Stop conversion on any invalid characters.
Return the current working directory in a newly allocated string.
(You should svz_free
it when done.)
Check for the current and maximum limit of open files of the current process and try to set the limit to max_sockets.
Transform the given binary data t (UTC time) to an ASCII time text representation without any trailing characters.
Convert the given string str to lower case text representation.
Return a statically-allocated string describing some operating system version details.
Return 1 if there was a "socket unavailable" error recently, 0
otherwise. This checks svz_errno
against WSAEWOULDBLOCK
(woe32) or EAGAIN
(Unix).
Return a string describing the most recent system error.
The next two functions log (with SVZ_LOG_ERROR
) the current
system error or network error, forming the prefix of the
message using fmt and args. This formatted prefix cannot
exceed 255 bytes. The rest of the message comprises: colon, space,
error description, newline.
Log the current system error.
Log the current network error.
Return 1 if running MinGW (Windows) NT4x or later, otherwise 0.
Next: Networking and other low level functions, Previous: svz_address_t, Up: Embedding API [Contents][Index]