Call open(.., .., mode) when O_TMPFILE is specified

Test case by Martin Pitt.