The "inuse" field protects the btree, the "session_ref" field protects the dhandle.  Unlock the handle if we don't attempt to discard it, or if the discard fails.