Miscellaneous C code.