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

Side by Side Diff: remoting/protocol/errors.cc

Issue 1238343002: Added ConnectionTimeObserver to calculate the times to authenticate and connect. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Removed unused headers. Created 5 years, 4 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 unified diff | Download patch
« no previous file with comments | « remoting/protocol/errors.h ('k') | remoting/remoting_srcs.gypi » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #include "remoting/protocol/errors.h"
6
7 #include "base/logging.h"
8
9 namespace remoting {
10 namespace protocol {
11
12 #define RETURN_STRING_LITERAL(x) \
13 case x: \
14 return #x;
15
16 const char* ErrorCodeToString(ErrorCode error) {
17 switch (error) {
18 RETURN_STRING_LITERAL(OK);
19 RETURN_STRING_LITERAL(PEER_IS_OFFLINE);
20 RETURN_STRING_LITERAL(SESSION_REJECTED);
21 RETURN_STRING_LITERAL(INCOMPATIBLE_PROTOCOL);
22 RETURN_STRING_LITERAL(AUTHENTICATION_FAILED);
23 RETURN_STRING_LITERAL(CHANNEL_CONNECTION_ERROR);
24 RETURN_STRING_LITERAL(SIGNALING_ERROR);
25 RETURN_STRING_LITERAL(SIGNALING_TIMEOUT);
26 RETURN_STRING_LITERAL(HOST_OVERLOAD);
27 RETURN_STRING_LITERAL(UNKNOWN_ERROR);
28 }
29 NOTREACHED();
30 return nullptr;
31 }
32
33 } // namespace protocol
34 } // namespace remoting
OLDNEW
« no previous file with comments | « remoting/protocol/errors.h ('k') | remoting/remoting_srcs.gypi » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698