Browse Source

command_line_interface: check if __APPLE__ is defined

Ben Boeckel 6 years ago
parent
commit
ec70372f85
1 changed files with 1 additions and 1 deletions
  1. 1 1
      src/google/protobuf/compiler/command_line_interface.cc

+ 1 - 1
src/google/protobuf/compiler/command_line_interface.cc

@@ -195,7 +195,7 @@ bool GetProtocAbsolutePath(std::string* path) {
 #ifdef _WIN32
   char buffer[MAX_PATH];
   int len = GetModuleFileNameA(NULL, buffer, MAX_PATH);
-#elif __APPLE__
+#elif defined(__APPLE__)
   char buffer[PATH_MAX];
   int len = 0;