Index: content/test/mock_google_streaming_server.cc |
diff --git a/content/test/mock_google_streaming_server.cc b/content/test/mock_google_streaming_server.cc |
index 5e13609060b11cc9f2df3e077d71d1dd72d5dbc7..5d8b846a6439f029a5825353b115cd39a54c62e7 100644 |
--- a/content/test/mock_google_streaming_server.cc |
+++ b/content/test/mock_google_streaming_server.cc |
@@ -14,6 +14,7 @@ |
#include "content/browser/speech/proto/google_streaming_api.pb.h" |
#include "content/browser/speech/speech_recognition_manager_impl.h" |
#include "net/base/escape.h" |
+#include "net/base/net_errors.h" |
#include "net/url_request/url_fetcher_delegate.h" |
#include "net/url_request/url_request_status.h" |
@@ -129,10 +130,8 @@ void MockGoogleStreamingServer::SimulateServerResponse( |
bool success, const std::string& http_response) { |
net::TestURLFetcher* fetcher = GetURLFetcher(true); |
- net::URLRequestStatus status; |
- status.set_status(success ? net::URLRequestStatus::SUCCESS : |
- net::URLRequestStatus::FAILED); |
- fetcher->set_status(status); |
+ fetcher->set_status( |
+ net::URLRequestStatus::FromError(success ? net::OK : net::ERR_FAILED)); |
fetcher->set_response_code(success ? 200 : 500); |
fetcher->SetResponseString(http_response); |
fetcher->delegate()->OnURLFetchDownloadProgress(fetcher, 0, 0); |