From 3a2a6c7c448f89fb294e6613b84b0ed72379c816 Mon Sep 17 00:00:00 2001 From: Jeremy Dubreil Date: Wed, 1 Jun 2016 22:48:24 -0700 Subject: [PATCH] Do not run the unsafe guarded access in prod Reviewed By: peterogithub Differential Revision: D3373791 fbshipit-source-id: 810aded --- infer/lib/python/inferlib/issues.py | 3 +- .../expected_outputs/ant_report.json | 40 ------------------- .../expected_outputs/buck_report.json | 40 ------------------- 3 files changed, 2 insertions(+), 81 deletions(-) diff --git a/infer/lib/python/inferlib/issues.py b/infer/lib/python/inferlib/issues.py index 2d9c36218..9b389c4d6 100644 --- a/infer/lib/python/inferlib/issues.py +++ b/infer/lib/python/inferlib/issues.py @@ -59,7 +59,8 @@ ISSUE_TYPES = [ 'REGISTERED_OBSERVER_BEING_DEALLOCATED', 'ASSIGN_POINTER_WARNING', 'GLOBAL_VARIABLE_INITIALIZED_WITH_FUNCTION_OR_METHOD_CALL', - 'UNSAFE_GUARDED_BY_ACCESS', + # TODO (t11307776): Turn this back on once some of the FP issues are fixed + # 'UNSAFE_GUARDED_BY_ACCESS', ] NULL_STYLE_ISSUE_TYPES = [ diff --git a/infer/tests/build_systems/expected_outputs/ant_report.json b/infer/tests/build_systems/expected_outputs/ant_report.json index bf9bdceeb..30b53189a 100644 --- a/infer/tests/build_systems/expected_outputs/ant_report.json +++ b/infer/tests/build_systems/expected_outputs/ant_report.json @@ -729,41 +729,6 @@ "file": "codetoanalyze/java/infer/ResourceLeaks.java", "procedure": "int ResourceLeaks.readConfigNotCloseStream(String)" }, - { - "bug_type": "UNSAFE_GUARDED_BY_ACCESS", - "file": "codetoanalyze/java/infer/GuardedByExample.java", - "procedure": "void GuardedByExample.readFAfterBlockBad()" - }, - { - "bug_type": "UNSAFE_GUARDED_BY_ACCESS", - "file": "codetoanalyze/java/infer/GuardedByExample.java", - "procedure": "void GuardedByExample.readFBad()" - }, - { - "bug_type": "UNSAFE_GUARDED_BY_ACCESS", - "file": "codetoanalyze/java/infer/GuardedByExample.java", - "procedure": "void GuardedByExample.readFBadWrongAnnotation()" - }, - { - "bug_type": "UNSAFE_GUARDED_BY_ACCESS", - "file": "codetoanalyze/java/infer/GuardedByExample.java", - "procedure": "void GuardedByExample.readFBadWrongLock()" - }, - { - "bug_type": "UNSAFE_GUARDED_BY_ACCESS", - "file": "codetoanalyze/java/infer/GuardedByExample.java", - "procedure": "void GuardedByExample.readGFromCopyBad()" - }, - { - "bug_type": "UNSAFE_GUARDED_BY_ACCESS", - "file": "codetoanalyze/java/infer/GuardedByExample.java", - "procedure": "void GuardedByExample.readHBad()" - }, - { - "bug_type": "UNSAFE_GUARDED_BY_ACCESS", - "file": "codetoanalyze/java/infer/GuardedByExample.java", - "procedure": "void GuardedByExample.readHBadSynchronizedMethodShouldntHelp()" - }, { "bug_type": "RESOURCE_LEAK", "file": "codetoanalyze/java/infer/ResourceLeaks.java", @@ -809,11 +774,6 @@ "file": "codetoanalyze/java/infer/CloseableAsResourceExample.java", "procedure": "T CloseableAsResourceExample.sourceOfNullWithResourceLeak()" }, - { - "bug_type": "UNSAFE_GUARDED_BY_ACCESS", - "file": "codetoanalyze/java/infer/GuardedByExample.java", - "procedure": "void GuardedByExample.synchronizedMethodBad()" - }, { "bug_type": "NULL_DEREFERENCE", "file": "codetoanalyze/java/infer/NullPointerExceptions.java", diff --git a/infer/tests/build_systems/expected_outputs/buck_report.json b/infer/tests/build_systems/expected_outputs/buck_report.json index 7b6ebec01..fb40efc16 100644 --- a/infer/tests/build_systems/expected_outputs/buck_report.json +++ b/infer/tests/build_systems/expected_outputs/buck_report.json @@ -734,41 +734,6 @@ "file": "infer/tests/codetoanalyze/java/infer/ResourceLeaks.java", "procedure": "int ResourceLeaks.readConfigNotCloseStream(String)" }, - { - "bug_type": "UNSAFE_GUARDED_BY_ACCESS", - "file": "infer/tests/codetoanalyze/java/infer/GuardedByExample.java", - "procedure": "void GuardedByExample.readFAfterBlockBad()" - }, - { - "bug_type": "UNSAFE_GUARDED_BY_ACCESS", - "file": "infer/tests/codetoanalyze/java/infer/GuardedByExample.java", - "procedure": "void GuardedByExample.readFBad()" - }, - { - "bug_type": "UNSAFE_GUARDED_BY_ACCESS", - "file": "infer/tests/codetoanalyze/java/infer/GuardedByExample.java", - "procedure": "void GuardedByExample.readFBadWrongAnnotation()" - }, - { - "bug_type": "UNSAFE_GUARDED_BY_ACCESS", - "file": "infer/tests/codetoanalyze/java/infer/GuardedByExample.java", - "procedure": "void GuardedByExample.readFBadWrongLock()" - }, - { - "bug_type": "UNSAFE_GUARDED_BY_ACCESS", - "file": "infer/tests/codetoanalyze/java/infer/GuardedByExample.java", - "procedure": "void GuardedByExample.readGFromCopyBad()" - }, - { - "bug_type": "UNSAFE_GUARDED_BY_ACCESS", - "file": "infer/tests/codetoanalyze/java/infer/GuardedByExample.java", - "procedure": "void GuardedByExample.readHBad()" - }, - { - "bug_type": "UNSAFE_GUARDED_BY_ACCESS", - "file": "infer/tests/codetoanalyze/java/infer/GuardedByExample.java", - "procedure": "void GuardedByExample.readHBadSynchronizedMethodShouldntHelp()" - }, { "bug_type": "RESOURCE_LEAK", "file": "infer/tests/codetoanalyze/java/infer/ResourceLeaks.java", @@ -814,11 +779,6 @@ "file": "infer/tests/codetoanalyze/java/infer/CloseableAsResourceExample.java", "procedure": "T CloseableAsResourceExample.sourceOfNullWithResourceLeak()" }, - { - "bug_type": "UNSAFE_GUARDED_BY_ACCESS", - "file": "infer/tests/codetoanalyze/java/infer/GuardedByExample.java", - "procedure": "void GuardedByExample.synchronizedMethodBad()" - }, { "bug_type": "NULL_DEREFERENCE", "file": "infer/tests/codetoanalyze/java/infer/NullPointerExceptions.java",