Skip to content

Commit

Permalink
logging.h related include-what-you-use (mojo/)
Browse files Browse the repository at this point in the history
Fix code that was implicitly depending on logging.h or its
dependencies.

For example, code that uses DISALLOW_COPY_AND_ASSIGN should
include base/macros.h, but it currently happens to work if
it pulls in logging.h directly or through some dependency.

This is part of refactoring the codebase to use
check.h/check_op.h for the CHECK and CHECK_op macro
instead of logging.h.

Bug: 1031540
Change-Id: I723f79de3ff4f75df75d899922980576db23551e
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2157105
Reviewed-by: Ken Rockot <rockot@google.com>
Commit-Queue: Ken Rockot <rockot@google.com>
Auto-Submit: Hans Wennborg <hans@chromium.org>
Cr-Commit-Position: refs/heads/master@{#761104}
  • Loading branch information
zmodem authored and Commit Bot committed Apr 21, 2020
1 parent eaf12fa commit 7c2ea37
Show file tree
Hide file tree
Showing 6 changed files with 9 additions and 0 deletions.
1 change: 1 addition & 0 deletions mojo/core/ports/event.cc
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
#include <stdint.h>
#include <string.h>

#include "base/logging.h"
#include "base/numerics/safe_math.h"
#include "mojo/core/ports/user_message.h"

Expand Down
1 change: 1 addition & 0 deletions mojo/public/cpp/platform/named_platform_channel_win.cc
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
// NOTE: This needs to be included *after* windows.h.
#include <sddl.h>

#include "base/logging.h"
#include "base/rand_util.h"
#include "base/strings/stringprintf.h"
#include "base/strings/utf_string_conversions.h"
Expand Down
2 changes: 2 additions & 0 deletions mojo/public/cpp/platform/socket_utils_posix.h
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@
#include <stddef.h>
#include <sys/types.h>

#include <vector>

#include "base/component_export.h"
#include "base/files/platform_file.h"
#include "base/files/scoped_file.h"
Expand Down
2 changes: 2 additions & 0 deletions mojo/public/cpp/system/data_pipe.cc
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@

#include "mojo/public/cpp/system/data_pipe.h"

#include "base/logging.h"

namespace mojo {

namespace {
Expand Down
1 change: 1 addition & 0 deletions mojo/public/cpp/system/platform_handle.cc
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@

#include "mojo/public/cpp/system/platform_handle.h"

#include "base/logging.h"
#include "base/memory/platform_shared_memory_region.h"
#include "base/numerics/safe_conversions.h"
#include "build/build_config.h"
Expand Down
2 changes: 2 additions & 0 deletions mojo/public/cpp/system/string_data_source.cc
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@

#include <algorithm>

#include "base/logging.h"

namespace mojo {

StringDataSource::StringDataSource(base::StringPiece data,
Expand Down

0 comments on commit 7c2ea37

Please sign in to comment.