rspec/rules/S899/jvm-description.adoc
Fred Tingaud d3cfe19d7e
Fix broken or dangerous backquotes
Co-authored-by: Marco Borgeaud <89914223+marco-antognini-sonarsource@users.noreply.github.com>
2023-10-30 10:33:56 +01:00

15 lines
534 B
Plaintext

When the return value of a function call contains the operation status code, this value should be tested to make sure the operation completed successfully.
This rule raises an issue when the return values of the following are ignored:
* `java.io.File` operations that return a status code (except `mkdirs`)
* `Iterator.hasNext()`
* `Enumeration.hasMoreElements()`
* `Lock.tryLock()`
* non-void ``++Condition.await*++`` methods
* `CountDownLatch.await(long, TimeUnit)`
* `Semaphore.tryAcquire`
* `BlockingQueue`: `offer`, `remove`