Clear FatalError when we start up. Comment enhancements
authorHeikki Linnakangas <[email protected]>
Mon, 23 Feb 2009 08:45:48 +0000 (10:45 +0200)
committerHeikki Linnakangas <[email protected]>
Mon, 23 Feb 2009 08:46:26 +0000 (10:46 +0200)
src/backend/postmaster/postmaster.c

index 0a06632922a7cc6e406106ad3293b12ac4fc922f..575223ad4e915bdae6cf0d7bb04e63824ba56edf 100644 (file)
@@ -225,7 +225,7 @@ static pid_t StartupPID = 0,
 static int     Shutdown = NoShutdown;
 
 static bool FatalError = false; /* T if recovering from backend crash */
-static bool RecoveryError = false; /* T if recovery failed */
+static bool RecoveryError = false; /* T if WAL recovery failed */
 
 /*
  * We use a simple state machine to control startup, shutdown, and
@@ -244,8 +244,8 @@ static bool RecoveryError = false; /* T if recovery failed */
  * could start accepting connections to perform read-only queries at this
  * point, if we had the infrastructure to do that.
  *
- * When the WAL redo is finished, the startup process exits with exit code 0
- * and we switch to PM_RUN state. The startup process can also skip the
+ * When WAL redo is finished, the startup process exits with exit code 0
+ * and we switch to PM_RUN state. Startup process can also skip the
  * recovery and consistent recovery phases altogether, as it will during
  * normal startup when there's no recovery to be done, for example.
  *
@@ -2193,6 +2193,7 @@ reaper(SIGNAL_ARGS)
                        /*
                         * Startup succeeded, commence normal operations
                         */
+                       FatalError = false;
                        pmState = PM_RUN;
 
                        /*