summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMark Salyzyn <salyzyn@google.com>2014-03-18 16:50:14 +0000
committerGerrit Code Review <noreply-gerritcodereview@google.com>2014-03-18 16:50:14 +0000
commit6c92369cbea460fded7e85f9751c6938000f504a (patch)
tree3c340f4c2ddaa974620fd4b92454d290e2e077c2
parent2beed9419443021d340690a0f36eea9baca44fec (diff)
parentfff04e3014f3ba516544be4ed345ddcf8ddac7fb (diff)
downloadcore-6c92369cbea460fded7e85f9751c6938000f504a.tar.gz
core-6c92369cbea460fded7e85f9751c6938000f504a.tar.bz2
core-6c92369cbea460fded7e85f9751c6938000f504a.zip
Merge "logcat: improve error messages"
-rw-r--r--logcat/logcat.cpp14
1 files changed, 7 insertions, 7 deletions
diff --git a/logcat/logcat.cpp b/logcat/logcat.cpp
index 7bf91a9af..596060973 100644
--- a/logcat/logcat.cpp
+++ b/logcat/logcat.cpp
@@ -699,7 +699,7 @@ int main(int argc, char **argv)
int ret;
ret = android_logger_clear(dev->logger);
if (ret) {
- perror("clearLog");
+ perror("failed to clear the log");
exit(EXIT_FAILURE);
}
}
@@ -707,7 +707,7 @@ int main(int argc, char **argv)
#ifdef USERDEBUG_BUILD
if (setLogSize && android_logger_set_log_size(dev->logger, setLogSize)) {
- perror("setLogSize");
+ perror("failed to set the log size");
exit(EXIT_FAILURE);
}
@@ -718,13 +718,13 @@ int main(int argc, char **argv)
size = android_logger_get_log_size(dev->logger);
if (size < 0) {
- perror("getLogSize");
+ perror("failed to get the log size");
exit(EXIT_FAILURE);
}
readable = android_logger_get_log_readable_size(dev->logger);
if (readable < 0) {
- perror("getLogReadableSize");
+ perror("failed to get the readable log size");
exit(EXIT_FAILURE);
}
@@ -748,7 +748,7 @@ int main(int argc, char **argv)
free(buf);
if (ret) {
- perror("setPruneList");
+ perror("failed to set the prune list");
exit(EXIT_FAILURE);
}
}
@@ -792,7 +792,7 @@ int main(int argc, char **argv)
}
if (!buf) {
- perror("response read");
+ perror("failed to read data");
exit(EXIT_FAILURE);
}
@@ -859,7 +859,7 @@ int main(int argc, char **argv)
fprintf(stderr, "read: unexpected length.\n");
exit(EXIT_FAILURE);
}
- perror("logcat read");
+ perror("logcat read failure");
exit(EXIT_FAILURE);
}