Merge "fiemap_writer: Use fallocate64" am: 032b744809
am: 06df12ba3b
Change-Id: Ifc1c6e48c1320171632bc7dfe6679cb4006f3f6a
diff --git a/fs_mgr/libfiemap_writer/fiemap_writer.cpp b/fs_mgr/libfiemap_writer/fiemap_writer.cpp
index b9b75f8..5b8a9c2 100644
--- a/fs_mgr/libfiemap_writer/fiemap_writer.cpp
+++ b/fs_mgr/libfiemap_writer/fiemap_writer.cpp
@@ -225,7 +225,7 @@
// don't come back unwritten. Return from this function with the kernel file offset set to 0.
// If the filesystem is f2fs, then we also PIN the file on disk to make sure the blocks
// aren't moved around.
- if (fallocate(file_fd, FALLOC_FL_ZERO_RANGE, 0, file_size)) {
+ if (fallocate64(file_fd, FALLOC_FL_ZERO_RANGE, 0, file_size)) {
PLOG(ERROR) << "Failed to allocate space for file: " << file_path << " size: " << file_size;
return false;
}