thread safety when using the non_blocking api

access to the iomux used in the async-io thread needs to be protected with a mutex
so that new readers won't try adding filedescriptors while it's being run

also minor fixes when trying to access obj->len after releasing the the obj->lock mutex