| OLD | NEW |
| 1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 // | 4 // |
| 5 // Contains the definition of a few helper functions used for generating sync | 5 // Contains the definition of a few helper functions used for generating sync |
| 6 // URLs. | 6 // URLs. |
| 7 | 7 |
| 8 #include "chrome/browser/sync/engine/net/url_translator.h" | 8 #include "chrome/browser/sync/engine/net/url_translator.h" |
| 9 | 9 |
| 10 #include "base/basictypes.h" | 10 #include "base/basictypes.h" |
| 11 #include "base/logging.h" | 11 #include "base/logging.h" |
| 12 #include "base/port.h" | 12 #include "base/port.h" |
| 13 #include "chrome/browser/sync/util/character_set_converters.h" | |
| 14 #include "net/base/escape.h" | 13 #include "net/base/escape.h" |
| 15 | 14 |
| 16 using std::string; | 15 using std::string; |
| 17 | 16 |
| 18 namespace browser_sync { | 17 namespace browser_sync { |
| 19 | 18 |
| 20 namespace { | 19 namespace { |
| 21 // Parameters that the server understands. (here, a-Z) | 20 // Parameters that the server understands. (here, a-Z) |
| 22 const char kParameterAuthToken[] = "auth"; | 21 const char kParameterAuthToken[] = "auth"; |
| 23 const char kParameterClientID[] = "client_id"; | 22 const char kParameterClientID[] = "client_id"; |
| (...skipping 17 matching lines...) Expand all Loading... |
| 41 } | 40 } |
| 42 | 41 |
| 43 string MakeSyncQueryString(const string& client_id) { | 42 string MakeSyncQueryString(const string& client_id) { |
| 44 string query; | 43 string query; |
| 45 query += kParameterClientID; | 44 query += kParameterClientID; |
| 46 query += "=" + CgiEscapeString(client_id); | 45 query += "=" + CgiEscapeString(client_id); |
| 47 return query; | 46 return query; |
| 48 } | 47 } |
| 49 | 48 |
| 50 } // namespace browser_sync | 49 } // namespace browser_sync |
| OLD | NEW |