Skip to content

Commit 421ac6d

Browse files
authored
style: include RCN_REDUNDANT_NULLCHECK_OF_NONNULL_VALUE (#6559)
1 parent f9a9ccb commit 421ac6d

File tree

2 files changed

+1
-4
lines changed

2 files changed

+1
-4
lines changed

spotbugs-exclude.xml

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -80,9 +80,6 @@
8080
<Match>
8181
<Bug pattern="SA_FIELD_SELF_ASSIGNMENT" />
8282
</Match>
83-
<Match>
84-
<Bug pattern="RCN_REDUNDANT_NULLCHECK_OF_NONNULL_VALUE" />
85-
</Match>
8683
<Match>
8784
<Bug pattern="AT_STALE_THREAD_WRITE_OF_PRIMITIVE" />
8885
</Match>

src/main/java/com/thealgorithms/datastructures/caches/LFUCache.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -132,7 +132,7 @@ public void put(K key, V value) {
132132
private void addNodeWithUpdatedFrequency(Node node) {
133133
if (tail != null && head != null) {
134134
Node temp = this.head;
135-
while (temp != null) {
135+
while (true) {
136136
if (temp.frequency > node.frequency) {
137137
if (temp == head) {
138138
node.next = temp;

0 commit comments

Comments
 (0)