Index: runtime/bin/log_android.cc |
diff --git a/runtime/bin/log_android.cc b/runtime/bin/log_android.cc |
index 6e5a6213f24ab707a5d2feffdcfa2ed2c9072d32..9dbbf05b0547b8b83affff66da01b9374789be12 100644 |
--- a/runtime/bin/log_android.cc |
+++ b/runtime/bin/log_android.cc |
@@ -17,10 +17,18 @@ namespace bin { |
// it when we see a '\n'. |
void Log::VPrint(const char* format, va_list args) { |
+ // If we launch the DartVM inside "adb shell" we will only get messages |
+ // (critical ones or not) if we print them to stdout/stderr. |
+ // We also log using android's logging system. |
+ vprintf(format, args); |
__android_log_vprint(ANDROID_LOG_INFO, "Dart", format, args); |
} |
void Log::VPrintErr(const char* format, va_list args) { |
+ // If we launch the DartVM inside "adb shell" we will only get messages |
+ // (critical ones or not) if we print them to stdout/stderr. |
+ // We also log using android's logging system. |
+ vfprintf(stderr, format, args); |
__android_log_vprint(ANDROID_LOG_ERROR, "Dart", format, args); |
} |