This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
D'oh! Don't try to do #ifdefs inside "functions" that are actually
authorNicholas Clark <nick@ccl4.org>
Wed, 12 Apr 2006 23:17:18 +0000 (23:17 +0000)
committerNicholas Clark <nick@ccl4.org>
Wed, 12 Apr 2006 23:17:18 +0000 (23:17 +0000)
macros.

p4raw-id: //depot/perl@27781

hv.c

diff --git a/hv.c b/hv.c
index f0f9c39..93853a9 100644 (file)
--- a/hv.c
+++ b/hv.c
@@ -2716,11 +2716,14 @@ Perl_refcounted_he_new(pTHX_ struct refcounted_he *const parent,
     }
     flags = value_type;
 
-    he = PerlMemShared_malloc(sizeof(struct refcounted_he) - 1
 #ifdef USE_ITHREADS
+    he = PerlMemShared_malloc(sizeof(struct refcounted_he) - 1
                              + key_len
-#endif
                              + key_offset);
+#else
+    he = PerlMemShared_malloc(sizeof(struct refcounted_he) - 1
+                             + key_offset);
+#endif
 
 
     he->refcounted_he_next = parent;