diff options
| author | Larry Hastings <larry@hastings.org> | 2015-03-30 08:50:00 (GMT) | 
|---|---|---|
| committer | Larry Hastings <larry@hastings.org> | 2015-03-30 08:50:00 (GMT) | 
| commit | 09dab7a87eaa7115eeaf73016d65f2f835e25986 (patch) | |
| tree | 04a83c1cfce64d3418a245feae7fee445e510949 /Python/dynload_shlib.c | |
| parent | 736240399e469a4134dac32a340feca5395baa28 (diff) | |
| parent | 45cff0c0e6c4a31ed3b5b88ee803320862fbd43a (diff) | |
| download | cpython-09dab7a87eaa7115eeaf73016d65f2f835e25986.zip cpython-09dab7a87eaa7115eeaf73016d65f2f835e25986.tar.gz cpython-09dab7a87eaa7115eeaf73016d65f2f835e25986.tar.bz2  | |
Merge 3.5.0a3 release engineering changes back into trunk.
Diffstat (limited to 'Python/dynload_shlib.c')
| -rw-r--r-- | Python/dynload_shlib.c | 14 | 
1 files changed, 6 insertions, 8 deletions
diff --git a/Python/dynload_shlib.c b/Python/dynload_shlib.c index 659adac..1a467fd 100644 --- a/Python/dynload_shlib.c +++ b/Python/dynload_shlib.c @@ -71,22 +71,20 @@ dl_funcptr _PyImport_GetDynLoadFunc(const char *shortname,      if (fp != NULL) {          int i; -        struct _Py_stat_struct statb; -        if (_Py_fstat(fileno(fp), &statb) == -1) { -            PyErr_SetFromErrno(PyExc_IOError); +        struct _Py_stat_struct status; +        if (_Py_fstat(fileno(fp), &status) == -1)              return NULL; -        }          for (i = 0; i < nhandles; i++) { -            if (statb.st_dev == handles[i].dev && -                statb.st_ino == handles[i].ino) { +            if (status.st_dev == handles[i].dev && +                status.st_ino == handles[i].ino) {                  p = (dl_funcptr) dlsym(handles[i].handle,                                         funcname);                  return p;              }          }          if (nhandles < 128) { -            handles[nhandles].dev = statb.st_dev; -            handles[nhandles].ino = statb.st_ino; +            handles[nhandles].dev = status.st_dev; +            handles[nhandles].ino = status.st_ino;          }      }  | 
