File tree Expand file tree Collapse file tree 2 files changed +13
-0
lines changed Expand file tree Collapse file tree 2 files changed +13
-0
lines changed Original file line number Diff line number Diff line change @@ -788,6 +788,14 @@ void do_coredump(const kernel_siginfo_t *siginfo)
788
788
if (displaced )
789
789
put_files_struct (displaced );
790
790
if (!dump_interrupted ()) {
791
+ /*
792
+ * umh disabled with CONFIG_STATIC_USERMODEHELPER_PATH="" would
793
+ * have this set to NULL.
794
+ */
795
+ if (!cprm .file ) {
796
+ pr_info ("Core dump to |%s disabled\n" , cn .corename );
797
+ goto close_fail ;
798
+ }
791
799
file_start_write (cprm .file );
792
800
core_dumped = binfmt -> core_dump (& cprm );
793
801
file_end_write (cprm .file );
Original file line number Diff line number Diff line change @@ -544,6 +544,11 @@ EXPORT_SYMBOL_GPL(fork_usermode_blob);
544
544
* Runs a user-space application. The application is started
545
545
* asynchronously if wait is not set, and runs as a child of system workqueues.
546
546
* (ie. it runs with full root capabilities and optimized affinity).
547
+ *
548
+ * Note: successful return value does not guarantee the helper was called at
549
+ * all. You can't rely on sub_info->{init,cleanup} being called even for
550
+ * UMH_WAIT_* wait modes as STATIC_USERMODEHELPER_PATH="" turns all helpers
551
+ * into a successful no-op.
547
552
*/
548
553
int call_usermodehelper_exec (struct subprocess_info * sub_info , int wait )
549
554
{
You can’t perform that action at this time.
0 commit comments