]> granicus.if.org Git - python/commitdiff
Patch for bug reported in patch #686627: import race condition in
authorMarc-André Lemburg <mal@egenix.com>
Fri, 14 Feb 2003 20:25:56 +0000 (20:25 +0000)
committerMarc-André Lemburg <mal@egenix.com>
Fri, 14 Feb 2003 20:25:56 +0000 (20:25 +0000)
codecs registry startup.

Python/codecs.c

index ec0daf380bf108100c56090f0eea9dc00f309c87..f987cd1a613237046748a60b571c31c14f63b43d 100644 (file)
@@ -38,7 +38,7 @@ int import_encodings(void)
     PyObject *mod;
     
     import_encodings_called = 1;
-    mod = PyImport_ImportModule("encodings");
+    mod = PyImport_ImportModuleEx("encodings", NULL, NULL, NULL);
     if (mod == NULL) {
        if (PyErr_ExceptionMatches(PyExc_ImportError)) {
            /* Ignore ImportErrors... this is done so that