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

Side by Side Diff: ui/gfx/x/x11_atom_cache.cc

Issue 2561963002: base: Remove the string logging from CHECK(). (Closed)
Patch Set: checkstring: rebase Created 4 years 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
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 #include "ui/gfx/x/x11_atom_cache.h" 5 #include "ui/gfx/x/x11_atom_cache.h"
6 6
7 #include <X11/Xatom.h> 7 #include <X11/Xatom.h>
8 #include <X11/Xlib.h> 8 #include <X11/Xlib.h>
9 9
10 #include <memory> 10 #include <memory>
(...skipping 24 matching lines...) Expand all
35 35
36 XAtom X11AtomCache::GetAtom(const char* name) const { 36 XAtom X11AtomCache::GetAtom(const char* name) const {
37 std::map<std::string, Atom>::const_iterator it = cached_atoms_.find(name); 37 std::map<std::string, Atom>::const_iterator it = cached_atoms_.find(name);
38 38
39 if (uncached_atoms_allowed_ && it == cached_atoms_.end()) { 39 if (uncached_atoms_allowed_ && it == cached_atoms_.end()) {
40 XAtom atom = XInternAtom(xdisplay_, name, false); 40 XAtom atom = XInternAtom(xdisplay_, name, false);
41 cached_atoms_.insert(std::make_pair(name, atom)); 41 cached_atoms_.insert(std::make_pair(name, atom));
42 return atom; 42 return atom;
43 } 43 }
44 44
45 CHECK(it != cached_atoms_.end()) << " Atom " << name << " not found"; 45 // Atom |name| not found
46 CHECK(it != cached_atoms_.end());
46 return it->second; 47 return it->second;
47 } 48 }
48 49
49 } // namespace ui 50 } // namespace ui
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698