Include <unistd.h> needed for close() function on Fedora.

The <fcntl.h> was not the correct header ...