Commit ffdb0bdf authored by hans's avatar hans Committed by Commit bot

Fix 'ordered comparison between pointer and zero' errors

The latest version of Clang rejects direct relational
comparison between null pointer constants and pointers.

BUG=none
TBR=justinlin

Review-Url: https://codereview.chromium.org/2448533002
Cr-Commit-Position: refs/heads/master@{#427093}
parent f65d37b5
......@@ -138,9 +138,7 @@ class ReadOnlyMappedFile {
}
}
// Returns true if the file was successfully mapped.
bool is_valid() const {
return ((start_ > 0) && (size_ > 0));
}
bool is_valid() const { return (start_ && (size_ > 0)); }
// Returns the size in bytes of the mapped memory.
uint32_t size() const { return size_; }
// Returns the memory backing the file.
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment