Date: Thu, 27 Apr 2017 14:36:52 +0200 From: Willem Jan Withagen <wjw@digiware.nl> To: "freebsd-hackers@freebsd.org" <freebsd-hackers@freebsd.org> Subject: Disabling program core dumps Message-ID: <32ac85ed-f0e5-2f80-299a-3bb1166cd5e6@digiware.nl>
next in thread | raw e-mail | index | archive | help
Hi, Running (googletest) tests some are expected to die: EXPECT_DEATH(). This normally dumps a core, but since it is expected that core is rather useless. Thusfar I've found the best way to limit a program to dump core (from within the program) is to set its RLIMIT_CORE to 0. So I can do this before the test, and then set the old size back once the test is finished. Or is there another way, like setting a flag in process state (which I have not been able to find) --WjW
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?32ac85ed-f0e5-2f80-299a-3bb1166cd5e6>