Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content
Commit 872a52c6 authored by Johannes Carlsson's avatar Johannes Carlsson Committed by Johan Redestig
Browse files

Closing cursor in finalizer to avoid GREF and fd leak in acore

The finalize() call did not clean up completely, this eventually
caused the android.process.acore to crash since it ran out of fds
and GREF to increased above 2000 if an application forgot to close
its cursor objects. A warning was also added when this happens so
that application developers can correct their mistake. The
included test case tries to verify that the finalizer works as
expected by creating a bunch of Cursor objects without closing
them (without this fix the acore process crashes after about 400
iterations and the test case ends with "Process crashed").

Change-Id: I11e485cef1ac02e718b2742108aa88793666c31d
parent fcf3d12d
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment