diff options
author | David Carlier <devnexen@gmail.com> | 2017-11-19 16:23:42 +0000 |
---|---|---|
committer | David Carlier <devnexen@gmail.com> | 2017-11-19 16:23:42 +0000 |
commit | 62689ef0cf3c805b100ff5260485368e1c9b683c (patch) | |
tree | b2e9e622ca53de8373f63877d04e448d77553e6e /src | |
parent | cf9a3f704850e82793239d9349ffa282eb9217f5 (diff) | |
download | redis-62689ef0cf3c805b100ff5260485368e1c9b683c.tar.gz |
Fix undefined behavior constant defined.
Diffstat (limited to 'src')
-rw-r--r-- | src/lzfP.h | 6 | ||||
-rw-r--r-- | src/setproctitle.c | 6 |
2 files changed, 10 insertions, 2 deletions
diff --git a/src/lzfP.h b/src/lzfP.h index c6d2e096c..93c27b42d 100644 --- a/src/lzfP.h +++ b/src/lzfP.h @@ -79,7 +79,11 @@ * Unconditionally aligning does not cost very much, so do it if unsure */ #ifndef STRICT_ALIGN -# define STRICT_ALIGN !(defined(__i386) || defined (__amd64)) +# if !(defined(__i386) || defined (__amd64)) +# define STRICT_ALIGN 1 +# else +# define STRICT_ALIGN 0 +# endif #endif /* diff --git a/src/setproctitle.c b/src/setproctitle.c index f44253e16..6563242de 100644 --- a/src/setproctitle.c +++ b/src/setproctitle.c @@ -39,7 +39,11 @@ #include <errno.h> /* errno program_invocation_name program_invocation_short_name */ #if !defined(HAVE_SETPROCTITLE) -#define HAVE_SETPROCTITLE (defined __NetBSD__ || defined __FreeBSD__ || defined __OpenBSD__) +#if (defined __NetBSD__ || defined __FreeBSD__ || defined __OpenBSD__) +#define HAVE_SETPROCTITLE 1 +#else +#define HAVE_SETPROCTITLE 0 +#endif #endif |