aboutsummaryrefslogtreecommitdiff
path: root/src/backend/tcop/postgres.c
diff options
context:
space:
mode:
authorTom Lane <tgl@sss.pgh.pa.us>2006-10-08 17:15:34 +0000
committerTom Lane <tgl@sss.pgh.pa.us>2006-10-08 17:15:34 +0000
commitc7611f99d63e316597b23720d5be354eb7438c72 (patch)
tree13efba7fdc706e586689d1772b2f51cebe147d32 /src/backend/tcop/postgres.c
parent5e0bc3b71113c6b766b0c9dfac87ae53889b29f8 (diff)
downloadpostgresql-c7611f99d63e316597b23720d5be354eb7438c72.tar.gz
postgresql-c7611f99d63e316597b23720d5be354eb7438c72.zip
On Windows, we know the backend stack size limit because we have to
specify it explicitly in backend/Makefile. Arrange for this value to be known by get_stack_depth_rlimit() too. Per suggestion from Magnus.
Diffstat (limited to 'src/backend/tcop/postgres.c')
-rw-r--r--src/backend/tcop/postgres.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/backend/tcop/postgres.c b/src/backend/tcop/postgres.c
index e22445b4745..369b40d2052 100644
--- a/src/backend/tcop/postgres.c
+++ b/src/backend/tcop/postgres.c
@@ -8,7 +8,7 @@
*
*
* IDENTIFICATION
- * $PostgreSQL: pgsql/src/backend/tcop/postgres.c,v 1.513 2006/10/07 20:16:57 tgl Exp $
+ * $PostgreSQL: pgsql/src/backend/tcop/postgres.c,v 1.514 2006/10/08 17:15:34 tgl Exp $
*
* NOTES
* this is the "main" module of the postgres backend and
@@ -3678,8 +3678,13 @@ get_stack_depth_rlimit(void)
}
return val;
#else /* no getrlimit */
+#if defined(WIN32) || defined(__CYGWIN__)
+ /* On Windows we set the backend stack size in src/backend/Makefile */
+ return WIN32_STACK_RLIMIT;
+#else /* not windows ... give up */
return -1;
#endif
+#endif
}