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

Side by Side Diff: tools/flags/SkCommandLineFlags.cpp

Issue 1073483002: Make --undefok a little louder now that we're using it all the time. (Closed) Base URL: https://skia.googlesource.com/skia@master
Patch Set: Created 5 years, 8 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 | « no previous file | no next file » | 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 2013 Google Inc. 2 * Copyright 2013 Google Inc.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license that can be 4 * Use of this source code is governed by a BSD-style license that can be
5 * found in the LICENSE file. 5 * found in the LICENSE file.
6 */ 6 */
7 7
8 #include "SkCommandLineFlags.h" 8 #include "SkCommandLineFlags.h"
9 #include "SkTDArray.h" 9 #include "SkTDArray.h"
10 #include "SkTSort.h" 10 #include "SkTSort.h"
(...skipping 295 matching lines...) Expand 10 before | Expand all | Expand 10 after
306 break; 306 break;
307 } 307 }
308 flag = flag->next(); 308 flag = flag->next();
309 } 309 }
310 if (!flagMatched) { 310 if (!flagMatched) {
311 #if SK_BUILD_FOR_MAC 311 #if SK_BUILD_FOR_MAC
312 if (SkStrStartsWith(argv[i], "NSDocumentRevisions")) { 312 if (SkStrStartsWith(argv[i], "NSDocumentRevisions")) {
313 i++; // skip YES 313 i++; // skip YES
314 } else 314 } else
315 #endif 315 #endif
316 if (!FLAGS_undefok) { 316 if (FLAGS_undefok) {
317 SkDebugf("Got unknown flag \"%s\". Exiting.\n", argv[i]); 317 SkDebugf("FYI: ignoring unknown flag '%s'.\n", argv[i]);
318 } else {
319 SkDebugf("Got unknown flag '%s'. Exiting.\n", argv[i]);
318 exit(-1); 320 exit(-1);
319 } 321 }
320 } 322 }
321 } 323 }
322 } 324 }
323 // Since all of the flags have been set, release the memory used by each 325 // Since all of the flags have been set, release the memory used by each
324 // flag. FLAGS_x can still be used after this. 326 // flag. FLAGS_x can still be used after this.
325 SkFlagInfo* flag = gHead; 327 SkFlagInfo* flag = gHead;
326 gHead = NULL; 328 gHead = NULL;
327 while (flag != NULL) { 329 while (flag != NULL) {
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after
369 } 371 }
370 372
371 } // namespace 373 } // namespace
372 374
373 bool SkCommandLineFlags::ShouldSkip(const SkTDArray<const char*>& strings, const char* name) { 375 bool SkCommandLineFlags::ShouldSkip(const SkTDArray<const char*>& strings, const char* name) {
374 return ShouldSkipImpl(strings, name); 376 return ShouldSkipImpl(strings, name);
375 } 377 }
376 bool SkCommandLineFlags::ShouldSkip(const StringArray& strings, const char* name ) { 378 bool SkCommandLineFlags::ShouldSkip(const StringArray& strings, const char* name ) {
377 return ShouldSkipImpl(strings, name); 379 return ShouldSkipImpl(strings, name);
378 } 380 }
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698