smbd: only open full fd for directories if needed