@@ -68,12 +68,6 @@ void goto_analyzer_parse_optionst::set_default_analysis_flags(
6868 options.set_option (" signed-overflow-check" , enabled);
6969 options.set_option (" undefined-shift-check" , enabled);
7070
71- // Default malloc failure profile chosen to be returning null. These options
72- // are not strictly *needed*, but they are staying here as part of documentation
73- // of the default option set for the tool.
74- options.set_option (" malloc-may-fail" , enabled);
75- options.set_option (" malloc-fail-null" , enabled);
76-
7771 // This is in-line with the options we set for CBMC in cbmc_parse_optionst
7872 // with the exception of unwinding-assertions, which don't make sense in
7973 // the context of abstract interpretation.
@@ -93,22 +87,6 @@ void goto_analyzer_parse_optionst::get_command_line_options(optionst &options)
9387 goto_analyzer_parse_optionst::set_default_analysis_flags (
9488 options, !cmdline.isset (" no-standard-checks" ));
9589
96- // Enable flags that in combination provide analysis with no surprises
97- // (expected checks and no unsoundness by missing checks).
98- if (!cmdline.isset (" no-standard-checks" ))
99- {
100- // The malloc failure mode is by default handled by the `config.set` call
101- // which only looks at the `cmdline` flags. In the case of default checks,
102- // these haven't been set - we need to overwrite the config object to manually
103- // bootstrap the malloc-may-fail behaviour
104- if (!config.ansi_c .malloc_may_fail && options.is_set (" malloc-may-fail" ))
105- {
106- config.ansi_c .malloc_may_fail = true ;
107- config.ansi_c .malloc_failure_mode =
108- configt::ansi_ct::malloc_failure_modet::malloc_failure_mode_return_null;
109- }
110- }
111-
11290 // all (other) checks supported by goto_check
11391 PARSE_OPTIONS_GOTO_CHECK (cmdline, options);
11492
0 commit comments