cleaned up kqueue.h, made open/read/write calls