Changeset 391 for python/trunk/Python/dynload_hpux.c
- Timestamp:
- Mar 19, 2014, 11:31:01 PM (11 years ago)
- Location:
- python/trunk
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
python/trunk
-
Property svn:mergeinfo
set to
/python/vendor/Python-2.7.6 merged eligible /python/vendor/current merged eligible
-
Property svn:mergeinfo
set to
-
python/trunk/Python/dynload_hpux.c
r2 r391 15 15 16 16 const struct filedescr _PyImport_DynLoadFiletab[] = { 17 18 19 17 {SHLIB_EXT, "rb", C_EXTENSION}, 18 {"module"SHLIB_EXT, "rb", C_EXTENSION}, 19 {0, 0} 20 20 }; 21 21 22 22 dl_funcptr _PyImport_GetDynLoadFunc(const char *fqname, const char *shortname, 23 23 const char *pathname, FILE *fp) 24 24 { 25 26 27 28 25 dl_funcptr p; 26 shl_t lib; 27 int flags; 28 char funcname[258]; 29 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 30 flags = BIND_FIRST | BIND_DEFERRED; 31 if (Py_VerboseFlag) { 32 flags = BIND_FIRST | BIND_IMMEDIATE | 33 BIND_NONFATAL | BIND_VERBOSE; 34 printf("shl_load %s\n",pathname); 35 } 36 lib = shl_load(pathname, flags, 0); 37 /* XXX Chuck Blake once wrote that 0 should be BIND_NOSTART? */ 38 if (lib == NULL) { 39 char buf[256]; 40 if (Py_VerboseFlag) 41 perror(pathname); 42 PyOS_snprintf(buf, sizeof(buf), "Failed to load %.200s", 43 pathname); 44 PyErr_SetString(PyExc_ImportError, buf); 45 return NULL; 46 } 47 PyOS_snprintf(funcname, sizeof(funcname), FUNCNAME_PATTERN, shortname); 48 if (Py_VerboseFlag) 49 printf("shl_findsym %s\n", funcname); 50 if (shl_findsym(&lib, funcname, TYPE_UNDEFINED, (void *) &p) == -1) { 51 shl_unload(lib); 52 p = NULL; 53 } 54 if (p == NULL && Py_VerboseFlag) 55 perror(funcname); 56 56 57 57 return p; 58 58 }
Note:
See TracChangeset
for help on using the changeset viewer.