]> granicus.if.org Git - postgresql/commitdiff
Only do find_my_exec if it doesn't come from the postmaster.
authorBruce Momjian <bruce@momjian.us>
Wed, 19 May 2004 19:39:27 +0000 (19:39 +0000)
committerBruce Momjian <bruce@momjian.us>
Wed, 19 May 2004 19:39:27 +0000 (19:39 +0000)
src/backend/tcop/postgres.c

index 3abbb46e0b798a517f66320ccfb31761397086e2..d4d1cd94738b36ba79c57ea4611b8c7368a19145 100644 (file)
@@ -8,7 +8,7 @@
  *
  *
  * IDENTIFICATION
- *       $PostgreSQL: pgsql/src/backend/tcop/postgres.c,v 1.410 2004/05/19 18:58:44 momjian Exp $
+ *       $PostgreSQL: pgsql/src/backend/tcop/postgres.c,v 1.411 2004/05/19 19:39:27 momjian Exp $
  *
  * NOTES
  *       this is the "main" module of the postgres backend and
@@ -2185,7 +2185,7 @@ PostgresMain(int argc, char *argv[], const char *username)
        /* Set up reference point for stack depth checking */
        stack_base_ptr = &stack_base;
 
-       if (find_my_exec(argv[0], my_exec_path) < 0)
+       if (my_exec_path[0] == '\0' && find_my_exec(argv[0], my_exec_path) < 0)
                elog(FATAL,
                                gettext("%s: could not locate my own executable path"),
                                                argv[0]);