summaryrefslogtreecommitdiffhomepage
path: root/dbutil.c
diff options
context:
space:
mode:
Diffstat (limited to 'dbutil.c')
-rw-r--r--dbutil.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/dbutil.c b/dbutil.c
index f06b8bf..4559ba9 100644
--- a/dbutil.c
+++ b/dbutil.c
@@ -693,3 +693,9 @@ void setnonblocking(int fd) {
}
TRACE(("leave setnonblocking"))
}
+
+void disallow_core() {
+ struct rlimit lim;
+ lim.rlim_cur = lim.rlim_max = 0;
+ setrlimit(RLIMIT_CORE, &lim);
+}