Change 27338 by [EMAIL PROTECTED] on 2006/02/27 13:28:04

        Workaround for initialization errors on HP's pre-compiler
        Do not ask me to explain. This re-definition works on AIX
        and HP-UX. Let's await the smokes.

Affected files ...

... //depot/perl/sv.c#1173 edit

Differences ...

==== //depot/perl/sv.c#1173 (text) ====
Index: perl/sv.c
--- perl/sv.c#1172~27334~       2006-02-27 03:06:30.000000000 -0800
+++ perl/sv.c   2006-02-27 05:28:04.000000000 -0800
@@ -875,9 +875,16 @@
    limited by PERL_ARENA_SIZE, so we can safely oversize the
    declarations.
  */
-#define FIT_ARENA(count, body_size)                    \
-    (!count || count * body_size > PERL_ARENA_SIZE)    \
-       ? (int)(PERL_ARENA_SIZE / body_size) * body_size : count * body_size
+#define FIT_ARENA0(body_size)                          \
+    ((size_t)(PERL_ARENA_SIZE / body_size) * body_size)
+#define FIT_ARENAn(count,body_size)                    \
+    ( count * body_size <= PERL_ARENA_SIZE)            \
+    ? count * body_size                                        \
+    : FIT_ARENA0 (body_size)
+#define FIT_ARENA(count,body_size)                     \
+    count                                              \
+    ? FIT_ARENAn (count, body_size)                    \
+    : FIT_ARENA0 (body_size)
 
 /* A macro to work out the offset needed to subtract from a pointer to (say)
 
End of Patch.

Reply via email to