[Python-Dev] Re: [Python-checkins] CVS: python/dist/src/Modules getpath.c,1.30,1.31
Fred L. Drake, Jr.
fdrake@beopen.com
Mon, 25 Sep 2000 13:04:18 -0400 (EDT)
Jeremy Hylton writes:
> fix bug #114290: when interpreter's argv[0] has a relative path make
> it absolute by joining it with getcwd result. avoid including
> unnecessary ./ in path but do not test for ../ (more complicated)
...
> + else if (argv0_path[0] == '.') {
> + getcwd(path, MAXPATHLEN);
> + if (argv0_path[1] == '/')
> + joinpath(path, argv0_path + 2);
Did you test this when argv[0] is something like './/foo/bin/python'?
-Fred
--
Fred L. Drake, Jr. <fdrake at beopen.com>
BeOpen PythonLabs Team Member