about summary refs log tree commit diff
path: root/src/libstd/sys/common/stack.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/libstd/sys/common/stack.rs')
-rw-r--r--src/libstd/sys/common/stack.rs11
1 files changed, 11 insertions, 0 deletions
diff --git a/src/libstd/sys/common/stack.rs b/src/libstd/sys/common/stack.rs
index 88bb9395cf1..cd5458a2109 100644
--- a/src/libstd/sys/common/stack.rs
+++ b/src/libstd/sys/common/stack.rs
@@ -241,6 +241,11 @@ pub unsafe fn record_sp_limit(limit: uint) {
     #[cfg(all(target_arch = "arm", target_os = "ios"))] #[inline(always)]
     unsafe fn target_record_sp_limit(_: uint) {
     }
+
+    #[cfg(target_os = "openbsd")] #[inline(always)]
+    unsafe fn target_record_sp_limit(_: uint) {
+        // segmented stack is disabled
+    }
 }
 
 /// The counterpart of the function above, this function will fetch the current
@@ -345,4 +350,10 @@ pub unsafe fn get_sp_limit() -> uint {
     unsafe fn target_get_sp_limit() -> uint {
         1024
     }
+
+    #[cfg(target_os = "openbsd")] #[inline(always)]
+    unsafe fn target_get_sp_limit() -> uint {
+        // segmented stack is disabled
+        1024
+    }
 }