diff options
author | Amaury Forgeot d'Arc <amauryfa@gmail.com> | 2009-07-25 16:22:06 (GMT) |
---|---|---|
committer | Amaury Forgeot d'Arc <amauryfa@gmail.com> | 2009-07-25 16:22:06 (GMT) |
commit | 982b2fa32dffb3e18862aa8d492c9d151a69cfe4 (patch) | |
tree | f63af3f7fa06f796ae348cc177b5708c35bec079 /Python | |
parent | 1ba9c873063965ac5d202c15aa8f4f9c32a22518 (diff) | |
download | cpython-982b2fa32dffb3e18862aa8d492c9d151a69cfe4.zip cpython-982b2fa32dffb3e18862aa8d492c9d151a69cfe4.tar.gz cpython-982b2fa32dffb3e18862aa8d492c9d151a69cfe4.tar.bz2 |
Better name a variable: 'buf' seems to imply a mutable buffer.
Diffstat (limited to 'Python')
-rw-r--r-- | Python/import.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/Python/import.c b/Python/import.c index 67c6cb2..055f081 100644 --- a/Python/import.c +++ b/Python/import.c @@ -1802,7 +1802,7 @@ static int init_builtin(char *); /* Forward */ its module object WITH INCREMENTED REFERENCE COUNT */ static PyObject * -load_module(char *name, FILE *fp, char *buf, int type, PyObject *loader) +load_module(char *name, FILE *fp, char *pathname, int type, PyObject *loader) { PyObject *modules; PyObject *m; @@ -1823,27 +1823,27 @@ load_module(char *name, FILE *fp, char *buf, int type, PyObject *loader) switch (type) { case PY_SOURCE: - m = load_source_module(name, buf, fp); + m = load_source_module(name, pathname, fp); break; case PY_COMPILED: - m = load_compiled_module(name, buf, fp); + m = load_compiled_module(name, pathname, fp); break; #ifdef HAVE_DYNAMIC_LOADING case C_EXTENSION: - m = _PyImport_LoadDynamicModule(name, buf, fp); + m = _PyImport_LoadDynamicModule(name, pathname, fp); break; #endif case PKG_DIRECTORY: - m = load_package(name, buf); + m = load_package(name, pathname); break; case C_BUILTIN: case PY_FROZEN: - if (buf != NULL && buf[0] != '\0') - name = buf; + if (pathname != NULL && pathname[0] != '\0') + name = pathname; if (type == C_BUILTIN) err = init_builtin(name); else |