Pledge should check m_has_promises. Calling pledge("", nullptr) does not fail on an already pledged process anymore.