ftruncate should succeed as long as the file descriptor is writable, even if the file doesn't have write permission. This is important when combined with O_CREAT. Reported by: pjdfstest Sponsored by: The FreeBSD Foundation