diff options
Diffstat (limited to 'src/port')
| -rw-r--r-- | src/port/dlopen.c | 2 | ||||
| -rw-r--r-- | src/port/pg_bitutils.c | 4 | ||||
| -rw-r--r-- | src/port/strtof.c | 13 |
3 files changed, 10 insertions, 9 deletions
diff --git a/src/port/dlopen.c b/src/port/dlopen.c index 6cca2eb370..05ad85b5b3 100644 --- a/src/port/dlopen.c +++ b/src/port/dlopen.c @@ -24,7 +24,7 @@ void * dlopen(const char *file, int mode) { - int flags = 0; + int flags = 0; if (mode & RTLD_NOW) flags |= BIND_IMMEDIATE; diff --git a/src/port/pg_bitutils.c b/src/port/pg_bitutils.c index d12765b33f..60fb55af53 100644 --- a/src/port/pg_bitutils.c +++ b/src/port/pg_bitutils.c @@ -203,7 +203,7 @@ pg_popcount32_asm(uint32 word) { uint32 res; - __asm__ __volatile__(" popcntl %1,%0\n" : "=q"(res) : "rm"(word) : "cc"); +__asm__ __volatile__(" popcntl %1,%0\n":"=q"(res):"rm"(word):"cc"); return (int) res; } @@ -216,7 +216,7 @@ pg_popcount64_asm(uint64 word) { uint64 res; - __asm__ __volatile__(" popcntq %1,%0\n" : "=q"(res) : "rm"(word) : "cc"); +__asm__ __volatile__(" popcntq %1,%0\n":"=q"(res):"rm"(word):"cc"); return (int) res; } diff --git a/src/port/strtof.c b/src/port/strtof.c index 9e37633bda..904cc5ff72 100644 --- a/src/port/strtof.c +++ b/src/port/strtof.c @@ -41,9 +41,9 @@ strtof(const char *nptr, char **endptr) * Value might be in-range for double but not float. */ if (dresult != 0 && fresult == 0) - caller_errno = ERANGE; /* underflow */ + caller_errno = ERANGE; /* underflow */ if (!isinf(dresult) && isinf(fresult)) - caller_errno = ERANGE; /* overflow */ + caller_errno = ERANGE; /* overflow */ } else caller_errno = errno; @@ -78,7 +78,7 @@ pg_strtof(const char *nptr, char **endptr) float fresult; errno = 0; - fresult = (strtof)(nptr, endptr); + fresult = (strtof) (nptr, endptr); if (errno) { /* On error, just return the error to the caller. */ @@ -100,7 +100,8 @@ pg_strtof(const char *nptr, char **endptr) /* * Try again. errno is already 0 here. */ - double dresult = strtod(nptr, NULL); + double dresult = strtod(nptr, NULL); + if (errno) { /* On error, just return the error */ @@ -113,8 +114,8 @@ pg_strtof(const char *nptr, char **endptr) errno = caller_errno; return fresult; } - else if ((dresult > 0 && dresult <= FLT_MIN && (float)dresult != 0.0) || - (dresult < 0 && dresult >= -FLT_MIN && (float)dresult != 0.0)) + else if ((dresult > 0 && dresult <= FLT_MIN && (float) dresult != 0.0) || + (dresult < 0 && dresult >= -FLT_MIN && (float) dresult != 0.0)) { /* subnormal but nonzero value */ errno = caller_errno; |
