Thread: pgsql-server: Path-mangling logic was failing to account for paths

pgsql-server: Path-mangling logic was failing to account for paths

From
tgl@svr1.postgresql.org (Tom Lane)
Date:
Log Message:
-----------
Path-mangling logic was failing to account for paths containing mentions
of '.' or '..'.  Extend canonicalize_path() to trim off trailing occurrences
of these things, and use it to fix up paths where needed (which I think is
only after places where we trim the last path component, but maybe some
others will turn up).  Fixes Josh's complaint that './initdb' does not
work.

Modified Files:
--------------
    pgsql-server/src/port:
        exec.c (r1.20 -> r1.21)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql-server/src/port/exec.c.diff?r1=1.20&r2=1.21)
        path.c (r1.26 -> r1.27)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql-server/src/port/path.c.diff?r1=1.26&r2=1.27)
    pgsql-server/src/bin/initdb:
        initdb.c (r1.46 -> r1.47)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql-server/src/bin/initdb/initdb.c.diff?r1=1.46&r2=1.47)