Fix incorrect use of TEMP_FAILURE_RETRY
TEMP_FAILURE_RETRY expects an argument that returns -1 on temporary
failure, not a boolean.
Test: TreeHugger
Change-Id: If8cb4a440e909c4ed7cbfdd34454670b0d5ee045
Exempt-From-Owner-Approval: Janitorial fix
diff --git a/identity/Util.cpp b/identity/Util.cpp
index a962dc3..cd29017 100644
--- a/identity/Util.cpp
+++ b/identity/Util.cpp
@@ -110,7 +110,7 @@
remaining -= numWritten;
}
- if (TEMP_FAILURE_RETRY(fsync(fd) == -1)) {
+ if (TEMP_FAILURE_RETRY(fsync(fd))) {
PLOG(ERROR) << "Failed fsyncing temp file for '" << path << "'";
close(fd);
return false;