1
0
mirror of https://github.com/postgres/postgres.git synced 2025-11-22 12:22:45 +03:00

Move find_my_exec() way up into main.c so it is available to the

timezone code and other places.

Remove elog() calls from find_my_exec;  do fprintf(stderr) instead.  We
can then remove the exec.c handling in the makefile because it doesn't
have to be built to suppress elog calls.
This commit is contained in:
Bruce Momjian
2004-05-18 20:18:59 +00:00
parent da401bd314
commit a9fad44372
10 changed files with 92 additions and 116 deletions

View File

@@ -13,7 +13,7 @@
*
*
* IDENTIFICATION
* $PostgreSQL: pgsql/src/backend/main/main.c,v 1.77 2004/04/19 17:42:57 momjian Exp $
* $PostgreSQL: pgsql/src/backend/main/main.c,v 1.78 2004/05/18 20:18:57 momjian Exp $
*
*-------------------------------------------------------------------------
*/
@@ -241,6 +241,14 @@ main(int argc, char *argv[])
#endif /* !WIN32 */
}
if (find_my_exec(argv[0], my_exec_path) < 0)
{
fprintf(stderr,
gettext("%s: could not locate my own executable path"),
argv[0]);
exit(1);
}
/*
* Now dispatch to one of PostmasterMain, PostgresMain, GucInfoMain,
* SubPostmasterMain, pgstat_main, pgstat_mainChild or BootstrapMain