Add errno tracking to database
Fix: don't long null FDs to database