Added POSIX library unistd.h for the function close() to be compatible with newer versions of G++