File tree 1 file changed +9
-2
lines changed
1 file changed +9
-2
lines changed Original file line number Diff line number Diff line change 37
37
*
38
38
*
39
39
* IDENTIFICATION
40
- * $PostgreSQL: pgsql/src/backend/postmaster/postmaster.c,v 1.456 2005/06/29 22:51:55 tgl Exp $
40
+ * $PostgreSQL: pgsql/src/backend/postmaster/postmaster.c,v 1.457 2005/06/30 10:02:22 petere Exp $
41
41
*
42
42
* NOTES
43
43
*
@@ -711,6 +711,7 @@ PostmasterMain(int argc, char *argv[])
711
711
char * rawstring ;
712
712
List * elemlist ;
713
713
ListCell * l ;
714
+ int success = 0 ;
714
715
715
716
/* Need a modifiable copy of ListenAddresses */
716
717
rawstring = pstrdup (ListenAddresses );
@@ -738,12 +739,18 @@ PostmasterMain(int argc, char *argv[])
738
739
(unsigned short ) PostPortNumber ,
739
740
UnixSocketDir ,
740
741
ListenSocket , MAXLISTEN );
741
- if (status != STATUS_OK )
742
+ if (status == STATUS_OK )
743
+ success ++ ;
744
+ else
742
745
ereport (WARNING ,
743
746
(errmsg ("could not create listen socket for \"%s\"" ,
744
747
curhost )));
745
748
}
746
749
750
+ if (!success && list_length (elemlist ))
751
+ ereport (FATAL ,
752
+ (errmsg ("could not create any TCP/IP sockets" )));
753
+
747
754
list_free (elemlist );
748
755
pfree (rawstring );
749
756
}
You can’t perform that action at this time.
0 commit comments