From 3046647478f584b665a33c3a1c3d1d6117979d64 Mon Sep 17 00:00:00 2001 From: Victor Stinner Date: Tue, 22 Feb 2011 23:16:19 +0000 Subject: Issue #3080: Remove unused argument of _PyImport_GetDynLoadFunc() The first argument, fqname, was not used. --- Python/dynload_hpux.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Python/dynload_hpux.c') diff --git a/Python/dynload_hpux.c b/Python/dynload_hpux.c index 18a81377f2..3ebbbad01f 100644 --- a/Python/dynload_hpux.c +++ b/Python/dynload_hpux.c @@ -19,7 +19,7 @@ const struct filedescr _PyImport_DynLoadFiletab[] = { {0, 0} }; -dl_funcptr _PyImport_GetDynLoadFunc(const char *fqname, const char *shortname, +dl_funcptr _PyImport_GetDynLoadFunc(const char *shortname, const char *pathname, FILE *fp) { dl_funcptr p; -- cgit v1.2.1 From 84a9491874cb99e24227206345f5a4b6060e27c8 Mon Sep 17 00:00:00 2001 From: Antoine Pitrou Date: Mon, 20 Feb 2012 19:41:11 +0100 Subject: Issue #14040: Remove rarely used file name suffixes for C extensions (under POSIX mainly). This will improve import performance a bit (especially under importlib). --- Python/dynload_hpux.c | 1 - 1 file changed, 1 deletion(-) (limited to 'Python/dynload_hpux.c') diff --git a/Python/dynload_hpux.c b/Python/dynload_hpux.c index 3ebbbad01f..1004010902 100644 --- a/Python/dynload_hpux.c +++ b/Python/dynload_hpux.c @@ -15,7 +15,6 @@ const struct filedescr _PyImport_DynLoadFiletab[] = { {SHLIB_EXT, "rb", C_EXTENSION}, - {"module"SHLIB_EXT, "rb", C_EXTENSION}, {0, 0} }; -- cgit v1.2.1 From 9750b728bb2c8b091f2919aecedc465c03de70a8 Mon Sep 17 00:00:00 2001 From: Brett Cannon Date: Fri, 20 Apr 2012 15:31:11 -0400 Subject: Issue #14599: Support ImportError.path on AIX and HPUX when loading extension modules. --- Python/dynload_hpux.c | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) (limited to 'Python/dynload_hpux.c') diff --git a/Python/dynload_hpux.c b/Python/dynload_hpux.c index 1004010902..6f0f2527b6 100644 --- a/Python/dynload_hpux.c +++ b/Python/dynload_hpux.c @@ -36,11 +36,21 @@ dl_funcptr _PyImport_GetDynLoadFunc(const char *shortname, /* XXX Chuck Blake once wrote that 0 should be BIND_NOSTART? */ if (lib == NULL) { char buf[256]; + PyObject *pathname_ob = NULL; + PyObject *buf_ob = NULL; + PyObject *shortname_ob = NULL; + if (Py_VerboseFlag) perror(pathname); PyOS_snprintf(buf, sizeof(buf), "Failed to load %.200s", pathname); - PyErr_SetString(PyExc_ImportError, buf); + buf_ob = PyUnicode_FromString(buf); + shortname_ob = PyUnicode_FromString(shortname); + pathname_ob = PyUnicode_FromString(pathname); + PyErr_SetImportError(buf_ob, shortname_ob, pathname_ob); + Py_DECREF(buf_ob); + Py_DECREF(shortname_ob); + Py_DECREF(pathname_ob); return NULL; } PyOS_snprintf(funcname, sizeof(funcname), FUNCNAME_PATTERN, shortname); -- cgit v1.2.1 From f9e12fdf7205afea929ddb2b8f6e950721c831bf Mon Sep 17 00:00:00 2001 From: Brett Cannon Date: Fri, 4 May 2012 15:20:40 -0400 Subject: Issue #13959: Re-implement imp.get_suffixes() in Lib/imp.py. This introduces a new function, imp.extension_suffixes(), which is currently undocumented. That is forthcoming once issue #14657 is resolved and how to expose file suffixes is decided. --- Python/dynload_hpux.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) (limited to 'Python/dynload_hpux.c') diff --git a/Python/dynload_hpux.c b/Python/dynload_hpux.c index 6f0f2527b6..c9554148cc 100644 --- a/Python/dynload_hpux.c +++ b/Python/dynload_hpux.c @@ -13,10 +13,7 @@ #define FUNCNAME_PATTERN "PyInit_%.200s" #endif -const struct filedescr _PyImport_DynLoadFiletab[] = { - {SHLIB_EXT, "rb", C_EXTENSION}, - {0, 0} -}; +const char *_PyImport_DynLoadFiletab[] = {SHLIB_EXT, NULL}; dl_funcptr _PyImport_GetDynLoadFunc(const char *shortname, const char *pathname, FILE *fp) -- cgit v1.2.1