ref: 989775c21c262c29a9a717f628f2cf8ea701806a dir: /libnpe/rename.c/
#include <unistd.h> int rename(char *old, char *new) { Dir d; nulldir(&d); d.name = new; return dirwstat(old, &d) > 0 ? 0 : -1; }