Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 290df6e8 authored by qctecmdr's avatar qctecmdr Committed by Gerrit - the friendly Code Review server
Browse files

Merge "coredump: fix crash when umh is disabled"

parents 83f269ef 86e56316
Loading
Loading
Loading
Loading
+8 −0
Original line number Diff line number Diff line
@@ -753,6 +753,14 @@ void do_coredump(const siginfo_t *siginfo)
	if (displaced)
		put_files_struct(displaced);
	if (!dump_interrupted()) {
		/*
		 * umh disabled with CONFIG_STATIC_USERMODEHELPER_PATH="" would
		 * have this set to NULL.
		 */
		if (!cprm.file) {
			pr_info("Core dump to |%s disabled\n", cn.corename);
			goto close_fail;
		}
		file_start_write(cprm.file);
		core_dumped = binfmt->core_dump(&cprm);
		file_end_write(cprm.file);