gbranden pushed a commit to branch master
in repository groff.

commit 32b4cdf7f25f5caf53b108e8e3919375160494eb
Author: G. Branden Robinson <[email protected]>
AuthorDate: Sun Nov 16 14:15:49 2025 -0600

    [tbl]: Fix inappropriate use of string literal.
    
    * src/preproc/tbl/table.cpp (table::init_output): Fix inappropriately
      hard-coded string literal.  Invoke the text block staggering macro via
      its existing preprocessor macro, not by its literal name.  Things will
      go wrong if we ever change that preprocessor macro's definition.
      Continues commit 2c8e354f22, 4 August 2023.  See Savannah #64454.
---
 ChangeLog                 | 9 +++++++++
 src/preproc/tbl/table.cpp | 2 +-
 2 files changed, 10 insertions(+), 1 deletion(-)

diff --git a/ChangeLog b/ChangeLog
index c43b31fa1..cbe6901ef 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,12 @@
+2025-11-16  G. Branden Robinson <[email protected]>
+
+       * src/preproc/tbl/table.cpp (table::init_output): Fix
+       inappropriately hard-coded string literal.  Invoke the text
+       block staggering macro via its existing preprocessor macro, not
+       by its literal name.  Things will go wrong if we ever change
+       that preprocessor macro's definition.  Continues commit
+       2c8e354f22, 4 August 2023.  See Savannah #64454.
+
 2025-11-15  G. Branden Robinson <[email protected]>
 
        [troff]: Slightly refactor; boolify `charinfo` member functions.
diff --git a/src/preproc/tbl/table.cpp b/src/preproc/tbl/table.cpp
index 24b80f50f..cbf9a06cd 100644
--- a/src/preproc/tbl/table.cpp
+++ b/src/preproc/tbl/table.cpp
@@ -1926,7 +1926,7 @@ void table::init_output()
         ".nr " SUPPRESS_BOTTOM_REG " 0\n"
         ".eo\n"
         ".de " TEXT_BLOCK_STAGGERING_MACRO "\n"
-        ".  ie !'\\n(.z'' \\!.3sp \"\\$1\"\n"
+        ".  ie !'\\n(.z'' \\!." TEXT_BLOCK_STAGGERING_MACRO "\"\\$1\"\n"
         ".  el .sp \\$1\n"
         "..\n"
         ".de " REPEATED_MARK_MACRO "\n"

_______________________________________________
groff-commit mailing list
[email protected]
https://lists.gnu.org/mailman/listinfo/groff-commit

Reply via email to