Home / Vulnerability Database / Kotlin : Method finalize() does not call super.finalize()
Kotlin

Kotlin : Method finalize() does not call super.finalize()

Classification

Overview

The finalize() method does not call super.finalize().

The finalize() method is defined in the Object Class and is called by the garbage collector on an object when garbage collection determines that there are no more references to the object. A subclass overrides the finalize method to dispose of system resources or to perform other cleanup.

The Java Language Specification states that it is a good practice for a finalize() method to call super.finalize(). Using super.finalize() and try-catch-finally block is a safety measure to ensure you do not unintentionally miss closing a resource used by the objects calling class.

LOW

DerScanner Severity Score

Do you want to fix Kotlin : Method finalize() does not call super.finalize() in your application?

See also

Kotlin

Kotlin : Missing required cryptographic step

Kotlin

Kotlin : Logging into system output

Kotlin

Kotlin : Call of notify() in synchronized block