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

Unified Diff: testing/android/native_test/native_test_launcher.cc

Issue 2540603004: [Android] Redirect std{in,out,err} to sockets for layout tests. (Closed)
Patch Set: rebase Created 3 years, 11 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
Index: testing/android/native_test/native_test_launcher.cc
diff --git a/testing/android/native_test/native_test_launcher.cc b/testing/android/native_test/native_test_launcher.cc
index 2389c731a681c50c71f145803bbdf7d30c9d7f9f..9547216defa6b486756c2f31fbd59fc1ad2905f6 100644
--- a/testing/android/native_test/native_test_launcher.cc
+++ b/testing/android/native_test/native_test_launcher.cc
@@ -14,7 +14,6 @@
#include "base/android/base_jni_registrar.h"
#include "base/android/context_utils.h"
-#include "base/android/fifo_utils.h"
#include "base/android/jni_string.h"
#include "base/android/scoped_java_ref.h"
#include "base/at_exit.h"
@@ -105,7 +104,7 @@ static void RunTests(JNIEnv* env,
// A few options, such "--gtest_list_tests", will just use printf directly
// Always redirect stdout to a known file.
- if (!base::android::RedirectStream(stdout, stdout_file_path, "a+")) {
+ if (freopen(stdout_file_path.value().c_str(), "a+", stdout) == NULL) {
AndroidLog(ANDROID_LOG_ERROR, "Failed to redirect stream to file: %s: %s\n",
stdout_file_path.value().c_str(), strerror(errno));
exit(EXIT_FAILURE);

Powered by Google App Engine
This is Rietveld 408576698