Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(895)

Unified Diff: examples/echo_terminal/main.cc

Issue 1355403002: enum class fixups - testing non-zero (Closed) Base URL: https://github.com/domokit/mojo.git@master
Patch Set: Created 5 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | services/files/directory_impl.cc » ('j') | services/files/directory_impl.cc » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: examples/echo_terminal/main.cc
diff --git a/examples/echo_terminal/main.cc b/examples/echo_terminal/main.cc
index 548a463aff46151c505972208205d71eb173361a..333b5c7cca4c4be41f729a9b0bc87dac1c374e2c 100644
--- a/examples/echo_terminal/main.cc
+++ b/examples/echo_terminal/main.cc
@@ -41,7 +41,7 @@ class TerminalEchoer {
// |Read()| callback:
void OnRead(mojo::files::Error error, mojo::Array<uint8_t> bytes_read) {
- if (error) {
+ if (mojo::files::ERROR_OK != error) {
viettrungluu 2015/09/22 22:04:58 In general, I (and most humans) prefer to read "er
johngro 2015/09/22 22:24:11 Done.
LOG(ERROR) << "Error: Read(): " << error;
delete this;
return;
@@ -71,7 +71,7 @@ class TerminalEchoer {
// |Write()| callback:
void OnWrite(mojo::files::Error error, uint32_t num_bytes_written) {
- if (error) {
+ if (mojo::files::ERROR_OK != error) {
LOG(ERROR) << "Error: Write(): " << error;
delete this;
return;
« no previous file with comments | « no previous file | services/files/directory_impl.cc » ('j') | services/files/directory_impl.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698