1
0
mirror of https://github.com/postgres/postgres.git synced 2025-07-15 19:21:59 +03:00

Add Win32 path handling for / vs. \ and drive letters.

This commit is contained in:
Bruce Momjian
2003-04-04 20:42:13 +00:00
parent 9bad936f67
commit d46e643822
22 changed files with 147 additions and 88 deletions

View File

@ -1,4 +1,4 @@
/* $Header: /cvsroot/pgsql/src/interfaces/ecpg/ecpglib/connect.c,v 1.1 2003/03/16 10:42:53 meskes Exp $ */
/* $Header: /cvsroot/pgsql/src/interfaces/ecpg/ecpglib/connect.c,v 1.2 2003/04/04 20:42:13 momjian Exp $ */
#include "postgres_fe.h"
@ -326,7 +326,7 @@ ECPGconnect(int lineno, const char *name, const char *user, const char *passwd,
*tmp = '\0';
}
tmp = strrchr(dbname + offset, '/');
tmp = last_path_separator(dbname + offset);
if (tmp != NULL) /* database name given */
{
realname = strdup(tmp + 1);