gpgscm: Avoid fruitless garbage collection cycles.
authorJustus Winter <justus@g10code.com>
Thu, 20 Apr 2017 13:04:52 +0000 (15:04 +0200)
committerJustus Winter <justus@g10code.com>
Mon, 24 Apr 2017 12:14:01 +0000 (14:14 +0200)
commit245860ecaf8b9e82ca577385abd453ac92ffcd26
tree2d3f978209d91a9999cb37ba2134c3c0ea4e537f
parent10519270d36586c536bfb6c4cda8ac17c01f4976
gpgscm: Avoid fruitless garbage collection cycles.

* tests/gpgscm/scheme-private.h (CELL_MINRECOVER): New macro.
* tests/gpgscm/scheme.c (_get_cell): Move the heuristic to get more
cells...
(gc): ... here where every caller benefits from the optimization.

Signed-off-by: Justus Winter <justus@g10code.com>
tests/gpgscm/scheme-private.h
tests/gpgscm/scheme.c