summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMike Frysinger <vapier@gentoo.org>2005-05-05 03:32:45 +0000
committerMike Frysinger <vapier@gentoo.org>2005-05-05 03:32:45 +0000
commite0b8ea9d73a587e0b3ca8a625fc149791d662fae (patch)
tree8ea92ffc80e71758afb165d7fbc23b66510f78c5 /sys-devel/m4/files
parentInstall as gm4 by default and drop in a m4 symlink on GNU systems #90858. (diff)
downloadhistorical-e0b8ea9d73a587e0b3ca8a625fc149791d662fae.tar.gz
historical-e0b8ea9d73a587e0b3ca8a625fc149791d662fae.tar.bz2
historical-e0b8ea9d73a587e0b3ca8a625fc149791d662fae.zip
Fix 64bit issues where pointers are stored in types which are too small #87873 by Matt Hargett.
Package-Manager: portage-2.0.51.21
Diffstat (limited to 'sys-devel/m4/files')
-rw-r--r--sys-devel/m4/files/m4-1.4.3-pointer.patch43
1 files changed, 43 insertions, 0 deletions
diff --git a/sys-devel/m4/files/m4-1.4.3-pointer.patch b/sys-devel/m4/files/m4-1.4.3-pointer.patch
new file mode 100644
index 000000000000..325fd55592df
--- /dev/null
+++ b/sys-devel/m4/files/m4-1.4.3-pointer.patch
@@ -0,0 +1,43 @@
+Grab changes from upstream gnulib CVS. We want to make sure
+that when we deal with pointers, we never try and store a pointer
+in a type that is smaller than the size of a pointer.
+
+http://bugs.gentoo.org/show_bug.cgi?id=87873
+
+--- lib/regex.c
++++ lib/regex.c
+@@ -1023,2 +1023,3 @@
+
++typedef unsigned long int active_reg_t;
+ #define PUSH_FAILURE_POINT(pattern_place, string_place, failure_code) \
+@@ -1028,3 +1029,3 @@
+ of 0 + -1 isn't done as unsigned. */ \
+- int this_reg; \
++ active_reg_t this_reg; \
+ \
+@@ -1135,3 +1136,3 @@
+ DEBUG_STATEMENT (fail_stack_elt_t failure_id;) \
+- int this_reg; \
++ active_reg_t this_reg; \
+ const unsigned char *string_temp; \
+@@ -1166,6 +1167,6 @@
+ /* Restore register info. */ \
+- high_reg = (unsigned) POP_FAILURE_ITEM (); \
++ high_reg = (active_reg_t) POP_FAILURE_ITEM (); \
+ DEBUG_PRINT2 (" Popping high active reg: %d\n", high_reg); \
+ \
+- low_reg = (unsigned) POP_FAILURE_ITEM (); \
++ low_reg = (active_reg_t) POP_FAILURE_ITEM (); \
+ DEBUG_PRINT2 (" Popping low active reg: %d\n", low_reg); \
+@@ -3406,4 +3407,4 @@
+ /* The currently active registers. */
+- unsigned lowest_active_reg = NO_LOWEST_ACTIVE_REG;
+- unsigned highest_active_reg = NO_HIGHEST_ACTIVE_REG;
++ active_reg_t lowest_active_reg = NO_LOWEST_ACTIVE_REG;
++ active_reg_t highest_active_reg = NO_HIGHEST_ACTIVE_REG;
+
+@@ -3992,3 +3993,3 @@
+ /* xx why this test? */
+- if ((int) old_regend[r] >= (int) regstart[r])
++ if (old_regend[r] >= regstart[r])
+ regend[r] = old_regend[r];