I notice that metamail had patches that do mktemp->mkstemp, but there are temp files left around as a result.