postgres.git / summary / log / commit / refs

commit    c004d68c9395812bfcff82c2d7c4e56d36e72f1c
Author:   Tom Lane <tgl@sss.pgh.pa.us>
Date:     Tue Dec 09 00:06:36 2025 +0000

    Fix minor portability issue in pg_resetwal.c.
    
    The argument of isspace() (like other <ctype.h> functions)
    must be cast to unsigned char to ensure portable results.
    
    Per NetBSD buildfarm members.  Oversight in 636c1914b.


src/bin/pg_resetwal/pg_resetwal.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/bin/pg_resetwal/pg_resetwal.c b/src/bin/pg_resetwal/pg_resetwal.c index c667a11cb6a..07c95f9ab80 100644 --- a/src/bin/pg_resetwal/pg_resetwal.c +++ b/src/bin/pg_resetwal/pg_resetwal.c @@ -1246,7 +1246,7 @@ strtouint32_strict(const char *restrict s, char **restrict endptr, int base) bool is_neg; /* skip leading whitespace */ - while (isspace(*s)) + while (isspace((unsigned char) *s)) s++; /* [parent: 83a26ba59b18]