Bug: new UnsupportedOperationException() not thrown in
org.eclipse.equinox.internal.p2.importexport.internal.wizard.ImportFromInstallationPage.setCheckedElements(Object[])

This code creates an exception (or error) object, but doesn't do
anything with it. For example, something like
if (x < 0) {
    new IllegalArgumentException("x must be nonnegative");
}


It was probably the intent of the programmer to throw the created
exception:
if (x < 0) {
    throw new IllegalArgumentException("x must be nonnegative");
}


Rank: Scariest (1), confidence: High
Pattern: RV_EXCEPTION_NOT_THROWN
Type: RV, Category: CORRECTNESS (Correctness)


Change-Id: I50c598c0d09ab05caf651d83463247278121e120
Signed-off-by: Carsten Hammer <carsten.hammer@t-online.de>
Reviewed-on: https://git.eclipse.org/r/c/equinox/rt.equinox.p2/+/171584
Tested-by: Equinox Bot <equinox-bot@eclipse.org>
Tested-by: Alexander Kurtakov <akurtako@redhat.com>
Reviewed-by: Alexander Kurtakov <akurtako@redhat.com>
3 files changed