This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
perldelta: Update Pod::Html’s version
[perl5.git] / ext / DynaLoader / dl_aix.xs
index c91a2fc..6d24428 100644 (file)
@@ -8,7 +8,7 @@
  *
  *  I did change all malloc's, free's, strdup's, calloc's to use the perl
  *  equilvant.  I also removed some stuff we will not need.  Call fini()
- *  on statup...   It can probably be trimmed more.
+ *  on startup...   It can probably be trimmed more.
  */
 
 #define PERLIO_NOT_STDIO 0
@@ -762,4 +762,19 @@ dl_error()
     OUTPUT:
     RETVAL
 
+#if defined(USE_ITHREADS)
+
+void
+CLONE(...)
+    CODE:
+    MY_CXT_CLONE;
+
+    /* MY_CXT_CLONE just does a memcpy on the whole structure, so to avoid
+     * using Perl variables that belong to another thread, we create our 
+     * own for this thread.
+     */
+    MY_CXT.x_dl_last_error = newSVpvn("", 0);
+
+#endif
+
 # end.