add unistd.h for close() calling