texinfo-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

branch master updated: unsigned char for isspace


From: Gavin D. Smith
Subject: branch master updated: unsigned char for isspace
Date: Thu, 14 Apr 2022 06:13:51 -0400

This is an automated email from the git hooks/post-receive script.

gavin pushed a commit to branch master
in repository texinfo.

The following commit(s) were added to refs/heads/master by this push:
     new 5c90b08a7b unsigned char for isspace
5c90b08a7b is described below

commit 5c90b08a7b9145aebc1d70960c5a7146615a7b05
Author: Gavin Smith <gavinsmith0123@gmail.com>
AuthorDate: Thu Apr 14 11:13:39 2022 +0100

    unsigned char for isspace
    
    * tp/Texinfo/XS/parsetexi/end_line.c (end_line_misc_line),
    * tp/Texinfo/XS/xspara.c (xspara_add_text):
    Cast argument to isspace to unsigned char.  This avoids varying
    test results on Solaris 10 and 11.
---
 ChangeLog                          | 9 +++++++++
 tp/Texinfo/XS/parsetexi/end_line.c | 6 +++---
 tp/Texinfo/XS/xspara.c             | 4 ++--
 3 files changed, 14 insertions(+), 5 deletions(-)

diff --git a/ChangeLog b/ChangeLog
index 6aafa95ad4..3877e6f6ee 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,12 @@
+2022-04-14  Gavin Smith  <gavinsmith0123@gmail.com>
+
+       unsigned char for isspace
+
+       * tp/Texinfo/XS/parsetexi/end_line.c (end_line_misc_line),
+       * tp/Texinfo/XS/xspara.c (xspara_add_text):
+       Cast argument to isspace to unsigned char.  This avoids varying
+       test results on Solaris 10 and 11.
+
 2022-04-12  Gavin Smith  <gavinsmith0123@gmail.com>
 
        CONVERT_TO_LATEX_IN_MATH
diff --git a/tp/Texinfo/XS/parsetexi/end_line.c 
b/tp/Texinfo/XS/parsetexi/end_line.c
index e1be5fcde9..cbc6e1ae12 100644
--- a/tp/Texinfo/XS/parsetexi/end_line.c
+++ b/tp/Texinfo/XS/parsetexi/end_line.c
@@ -1,5 +1,5 @@
 /* end_line.c -- what to do at the end of a whole line of input */
-/* Copyright 2010-2021 Free Software Foundation, Inc.
+/* Copyright 2010-2022 Free Software Foundation, Inc.
 
    This program is free software: you can redistribute it and/or modify
    it under the terms of the GNU General Public License as published by
@@ -1658,14 +1658,14 @@ end_line_misc_line (ELEMENT *current)
           p = convert_to_texinfo (args_child_by_index(current, 0));
 
           texi_line = p;
-          while (isspace (*texi_line))
+          while (isspace ((unsigned char) *texi_line))
             texi_line++;
 
           /* Trim leading and trailing whitespace. */
           p1 = strchr (texi_line, '\0');
           if (p1 > texi_line)
             {
-              while (p1 > texi_line && isspace (p1[-1]))
+              while (p1 > texi_line && isspace ((unsigned char) p1[-1]))
                 p1--;
               c = *p1;
               *p1 = '\0';
diff --git a/tp/Texinfo/XS/xspara.c b/tp/Texinfo/XS/xspara.c
index 4664c6b50a..09980035cc 100644
--- a/tp/Texinfo/XS/xspara.c
+++ b/tp/Texinfo/XS/xspara.c
@@ -1,4 +1,4 @@
-/* Copyright 2010-2021 Free Software Foundation, Inc.
+/* Copyright 2010-2022 Free Software Foundation, Inc.
 
    This program is free software: you can redistribute it and/or modify
    it under the terms of the GNU General Public License as published by
@@ -867,7 +867,7 @@ xspara_add_text (char *text)
           continue;
         }
 
-      if (isspace (*p))
+      if (isspace ((unsigned char) *p))
         {
           state.last_letter = L'\0';
 



reply via email to

[Prev in Thread] Current Thread [Next in Thread]