summaryrefslogtreecommitdiff
path: root/pkg/less/patch/0001-Remove-after-function-definition.patch
diff options
context:
space:
mode:
authorMichael Forney <mforney@mforney.org>2019-07-05 22:25:46 -0700
committerMichael Forney <mforney@mforney.org>2019-07-06 15:04:53 -0700
commita3b6be9a0e6dfa4e85bc49d59d7b816605fc29b3 (patch)
tree65efb85754cd2441e9f5608709787cbb344c5995 /pkg/less/patch/0001-Remove-after-function-definition.patch
parente2e5e98bcd0badcd437b8a67aa0986ed6d6678a9 (diff)
less: Fix a few portability issues
Diffstat (limited to 'pkg/less/patch/0001-Remove-after-function-definition.patch')
-rw-r--r--pkg/less/patch/0001-Remove-after-function-definition.patch29
1 files changed, 29 insertions, 0 deletions
diff --git a/pkg/less/patch/0001-Remove-after-function-definition.patch b/pkg/less/patch/0001-Remove-after-function-definition.patch
new file mode 100644
index 00000000..db8658f0
--- /dev/null
+++ b/pkg/less/patch/0001-Remove-after-function-definition.patch
@@ -0,0 +1,29 @@
+From 5c87a344bc528c1878708c5e497f0e8e1742b7d4 Mon Sep 17 00:00:00 2001
+From: Michael Forney <mforney@mforney.org>
+Date: Fri, 5 Jul 2019 22:05:36 -0700
+Subject: [PATCH] Remove ';' after function definition
+
+The STR_TO_TYPE_FUNC macro expands to a function definition, so the ';'
+is treated as an empty top-level declaration, which is not valid in ISO C.
+---
+ output.c | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/output.c b/output.c
+index 100eb79..d1d20c4 100644
+--- a/output.c
++++ b/output.c
+@@ -493,8 +493,8 @@ type funcname(buf, ebuf) \
+ return val; \
+ }
+
+-STR_TO_TYPE_FUNC(lstrtopos, POSITION);
+-STR_TO_TYPE_FUNC(lstrtoi, int);
++STR_TO_TYPE_FUNC(lstrtopos, POSITION)
++STR_TO_TYPE_FUNC(lstrtoi, int)
+
+ /*
+ * Output an integer in a given radix.
+--
+2.22.0
+