if (posix_fallocate(fd, st.st_size, size - st.st_size) == 0)
return 0;
- if (errno != EINVAL) {
+ if (errno != EINVAL /* Solaris */ &&
+ errno != ENOPROTOOPT /* AIX */) {
if (!ENOSPACE(errno))
i_error("posix_fallocate() failed: %m");
return -1;
}
- /* Solaris seems to fail with EINVAL if it's not supported
- by the kernel. Fallback to writing. */
+ /* Not supported by kernel, fallback to writing. */
posix_fallocate_supported = FALSE;
}
#endif