Dont try to save the errno in RecoveryConflictInterrupt to avoid confusion. feature/hs-cleanup
authorAndres Freund <[email protected]>
Sun, 14 Feb 2010 10:24:45 +0000 (11:24 +0100)
committerAndres Freund <[email protected]>
Sun, 14 Feb 2010 23:02:07 +0000 (00:02 +0100)
In the current state the errno saving in there is confusing as there
are several returns ignoring to set it. I think its currently harmless
as there should be no changes to errno at those places - beside that
the only caller (procsignal_sigusr1_handler) already saves it.

src/backend/tcop/postgres.c

index 8c0c8b9c88d1c58a30400b0b55c4a77a868b857a..3505fc430ce6f31a4b36ae18d7ec6d7971fb8849 100644 (file)
@@ -2753,11 +2753,9 @@ SigHupHandler(SIGNAL_ARGS)
 void
 RecoveryConflictInterrupt(ProcSignalReason reason)
 {
-   int                     save_errno = errno;
-
    /*
-   * Don't joggle the elbow of proc_exit
-   */
+    * Don't joggle the elbow of proc_exit
+    */
    if (!proc_exit_inprogress)
    {
        RecoveryConflictReason = reason;
@@ -2856,8 +2854,6 @@ RecoveryConflictInterrupt(ProcSignalReason reason)
            ProcessInterrupts();
        }
    }
-
-   errno = save_errno;
 }
 
 /*