[infer][checkers] add an option to enable the Fragment View Checker

Summary: There was no option to trigger this checker so it was not possible to enable it when not running the default list of checkers

Reviewed By: jberdine

Differential Revision: D5057088

fbshipit-source-id: 7af36f5
master
Jeremy Dubreil 8 years ago committed by Facebook Github Bot
parent a56ac06c7e
commit f43e18b7b6

@ -922,6 +922,10 @@ and flavors =
"Buck integration using Buck flavors (clang only), eg $(i,`infer --flavors -- buck build \ "Buck integration using Buck flavors (clang only), eg $(i,`infer --flavors -- buck build \
//foo:bar#infer`)" //foo:bar#infer`)"
and fragment_retains_view =
CLOpt.mk_bool ~long:"fragment-retains-view" ~in_help:CLOpt.[Analyze, manual_generic]
"detects when Android fragments are not explicitly nullified before becoming unreabable"
and from_json_report = and from_json_report =
CLOpt.mk_path_opt ~long:"from-json-report" CLOpt.mk_path_opt ~long:"from-json-report"
~in_help:CLOpt.[Report, manual_generic] ~in_help:CLOpt.[Report, manual_generic]
@ -1719,6 +1723,7 @@ and filter_paths = !filter_paths
and filter_report_paths = !filter_report_paths and filter_report_paths = !filter_report_paths
and filtering = !filtering and filtering = !filtering
and flavors = !flavors and flavors = !flavors
and fragment_retains_view = !fragment_retains_view
and from_json_report = !from_json_report and from_json_report = !from_json_report
and frontend_debug = !frontend_debug and frontend_debug = !frontend_debug
and frontend_stats = !frontend_stats and frontend_stats = !frontend_stats

@ -235,6 +235,7 @@ val filter_paths : bool
val filter_report_paths : string option val filter_report_paths : string option
val filtering : bool val filtering : bool
val flavors : bool val flavors : bool
val fragment_retains_view : bool
val from_json_report : string option val from_json_report : string option
val frontend_debug : bool val frontend_debug : bool
val frontend_tests : bool val frontend_tests : bool

@ -26,7 +26,8 @@ let active_procedure_checkers () =
let java_checkers = let java_checkers =
let l = let l =
[ [
FragmentRetainsViewChecker.callback_fragment_retains_view, enabled_by_default; FragmentRetainsViewChecker.callback_fragment_retains_view, enabled_by_default
|| Config.fragment_retains_view;
Eradicate.callback_eradicate, Config.eradicate; Eradicate.callback_eradicate, Config.eradicate;
BoundedCallTree.checker, Config.crashcontext; BoundedCallTree.checker, Config.crashcontext;
JavaTaintAnalysis.checker, Config.quandary || enabled_by_default; JavaTaintAnalysis.checker, Config.quandary || enabled_by_default;

Loading…
Cancel
Save