Skip to content

Commit

Permalink
change '#if _MSC_VER' to '#ifdef _MSC_VER' (#987)
Browse files Browse the repository at this point in the history
  • Loading branch information
jmklix authored Feb 28, 2023
1 parent e64e1cc commit 5cf17cd
Show file tree
Hide file tree
Showing 5 changed files with 8 additions and 8 deletions.
4 changes: 2 additions & 2 deletions include/aws/common/private/lookup3.inl
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ on 1 byte), but shoehorning those bytes into integers efficiently is messy.
# include <endian.h> /* attempt to define endianness */
#endif

#if _MSC_VER
#ifdef _MSC_VER
#pragma warning(push)
#pragma warning(disable:4127) /*Disable "conditional expression is constant" */
#endif /* _MSC_VER */
Expand Down Expand Up @@ -1055,7 +1055,7 @@ int main()
#endif /* SELF_TEST */


#if _MSC_VER
#ifdef _MSC_VER
#pragma warning(pop)
#endif /* _MSC_VER */

Expand Down
2 changes: 1 addition & 1 deletion include/aws/testing/aws_test_harness.h
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ the AWS_UNSTABLE_TESTING_API compiler flag
# define AWS_TESTING_REPORT_FD stderr
#endif

#if _MSC_VER
#ifdef _MSC_VER
# pragma warning(disable : 4221) /* aggregate initializer using local variable addresses */
# pragma warning(disable : 4204) /* non-constant aggregate initializer */
#endif
Expand Down
2 changes: 1 addition & 1 deletion source/log_formatter.c
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
* Default formatter implementation
*/

#if _MSC_VER
#ifdef _MSC_VER
# pragma warning(disable : 4204) /* non-constant aggregate initializer */
#endif

Expand Down
6 changes: 3 additions & 3 deletions source/logging.c
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
#include <errno.h>
#include <stdarg.h>

#if _MSC_VER
#ifdef _MSC_VER
# pragma warning(disable : 4204) /* non-constant aggregate initializer */
#endif

Expand Down Expand Up @@ -468,7 +468,7 @@ static int s_noalloc_stderr_logger_log(
va_list format_args;
va_start(format_args, format);

#if _MSC_VER
#ifdef _MSC_VER
# pragma warning(push)
# pragma warning(disable : 4221) /* allow struct member to reference format_buffer */
#endif
Expand All @@ -484,7 +484,7 @@ static int s_noalloc_stderr_logger_log(
.amount_written = 0,
};

#if _MSC_VER
#ifdef _MSC_VER
# pragma warning(pop) /* disallow struct member to reference local value */
#endif

Expand Down
2 changes: 1 addition & 1 deletion source/uri.c
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
#include <stdio.h>
#include <string.h>

#if _MSC_VER
#ifdef _MSC_VER
# pragma warning(disable : 4221) /* aggregate initializer using local variable addresses */
# pragma warning(disable : 4204) /* non-constant aggregate initializer */
#endif
Expand Down

0 comments on commit 5cf17cd

Please sign in to comment.