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

Side by Side Diff: webrtc/base/stringencode.h

Issue 1344143002: Catching more errors when parsing ICE server URLs. (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Merging with master. Created 5 years, 2 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 | « talk/app/webrtc/peerconnectioninterface_unittest.cc ('k') | webrtc/base/stringencode.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright 2004 The WebRTC Project Authors. All rights reserved. 2 * Copyright 2004 The WebRTC Project Authors. All rights reserved.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license 4 * Use of this source code is governed by a BSD-style license
5 * that can be found in the LICENSE file in the root of the source 5 * that can be found in the LICENSE file in the root of the source
6 * tree. An additional intellectual property rights grant can be found 6 * tree. An additional intellectual property rights grant can be found
7 * in the file PATENTS. All contributing project authors may 7 * in the file PATENTS. All contributing project authors may
8 * be found in the AUTHORS file in the root of the source tree. 8 * be found in the AUTHORS file in the root of the source tree.
9 */ 9 */
10 10
(...skipping 128 matching lines...) Expand 10 before | Expand all | Expand 10 after
139 // Splits the source string into multiple fields separated by delimiter, 139 // Splits the source string into multiple fields separated by delimiter,
140 // with duplicates of delimiter creating empty fields. 140 // with duplicates of delimiter creating empty fields.
141 size_t split(const std::string& source, char delimiter, 141 size_t split(const std::string& source, char delimiter,
142 std::vector<std::string>* fields); 142 std::vector<std::string>* fields);
143 143
144 // Splits the source string into multiple fields separated by delimiter, 144 // Splits the source string into multiple fields separated by delimiter,
145 // with duplicates of delimiter ignored. Trailing delimiter ignored. 145 // with duplicates of delimiter ignored. Trailing delimiter ignored.
146 size_t tokenize(const std::string& source, char delimiter, 146 size_t tokenize(const std::string& source, char delimiter,
147 std::vector<std::string>* fields); 147 std::vector<std::string>* fields);
148 148
149 // Tokenize, including the empty tokens.
150 size_t tokenize_with_empty_tokens(const std::string& source,
151 char delimiter,
152 std::vector<std::string>* fields);
153
149 // Tokenize and append the tokens to fields. Return the new size of fields. 154 // Tokenize and append the tokens to fields. Return the new size of fields.
150 size_t tokenize_append(const std::string& source, char delimiter, 155 size_t tokenize_append(const std::string& source, char delimiter,
151 std::vector<std::string>* fields); 156 std::vector<std::string>* fields);
152 157
153 // Splits the source string into multiple fields separated by delimiter, with 158 // Splits the source string into multiple fields separated by delimiter, with
154 // duplicates of delimiter ignored. Trailing delimiter ignored. A substring in 159 // duplicates of delimiter ignored. Trailing delimiter ignored. A substring in
155 // between the start_mark and the end_mark is treated as a single field. Return 160 // between the start_mark and the end_mark is treated as a single field. Return
156 // the size of fields. For example, if source is "filename 161 // the size of fields. For example, if source is "filename
157 // \"/Library/Application Support/media content.txt\"", delimiter is ' ', and 162 // \"/Library/Application Support/media content.txt\"", delimiter is ' ', and
158 // the start_mark and end_mark are '"', this method returns two fields: 163 // the start_mark and end_mark are '"', this method returns two fields:
(...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after
210 215
211 // simple function to strip out characters which shouldn't be 216 // simple function to strip out characters which shouldn't be
212 // used in filenames 217 // used in filenames
213 char make_char_safe_for_filename(char c); 218 char make_char_safe_for_filename(char c);
214 219
215 ////////////////////////////////////////////////////////////////////// 220 //////////////////////////////////////////////////////////////////////
216 221
217 } // namespace rtc 222 } // namespace rtc
218 223
219 #endif // WEBRTC_BASE_STRINGENCODE_H__ 224 #endif // WEBRTC_BASE_STRINGENCODE_H__
OLDNEW
« no previous file with comments | « talk/app/webrtc/peerconnectioninterface_unittest.cc ('k') | webrtc/base/stringencode.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698