From 2b25fd7da030e166d9848f18634ca4ea30124a29 Mon Sep 17 00:00:00 2001 From: Mehmet Fidanboylu Date: Tue, 18 Sep 2018 19:43:26 -0700 Subject: [PATCH] Don't use unix or win namespaces (#6277) --- fml/unique_fd.cc | 8 ++++---- fml/unique_fd.h | 12 ++++++------ 2 files changed, 10 insertions(+), 10 deletions(-) diff --git a/fml/unique_fd.cc b/fml/unique_fd.cc index 45fd7613086..09226c60149 100644 --- a/fml/unique_fd.cc +++ b/fml/unique_fd.cc @@ -11,23 +11,23 @@ namespace internal { #if OS_WIN -namespace win { +namespace os_win { void UniqueFDTraits::Free(HANDLE fd) { CloseHandle(fd); } -} // namespace win +} // namespace os_win #else // OS_WIN -namespace unix { +namespace os_unix { void UniqueFDTraits::Free(int fd) { close(fd); } -} // namespace unix +} // namespace os_unix #endif // OS_WIN diff --git a/fml/unique_fd.h b/fml/unique_fd.h index ac5b983bc8c..05dee99018f 100644 --- a/fml/unique_fd.h +++ b/fml/unique_fd.h @@ -23,7 +23,7 @@ namespace internal { #if OS_WIN -namespace win { +namespace os_win { struct UniqueFDTraits { static HANDLE InvalidValue() { return INVALID_HANDLE_VALUE; } @@ -31,11 +31,11 @@ struct UniqueFDTraits { static void Free(HANDLE fd); }; -} // namespace win +} // namespace os_win #else // OS_WIN -namespace unix { +namespace os_unix { struct UniqueFDTraits { static int InvalidValue() { return -1; } @@ -43,7 +43,7 @@ struct UniqueFDTraits { static void Free(int fd); }; -} // namespace unix +} // namespace os_unix #endif // OS_WIN @@ -51,11 +51,11 @@ struct UniqueFDTraits { #if OS_WIN -using UniqueFD = UniqueObject; +using UniqueFD = UniqueObject; #else // OS_WIN -using UniqueFD = UniqueObject; +using UniqueFD = UniqueObject; #endif // OS_WIN