diff options
author | Justus Winter <[email protected]> | 2017-04-04 15:36:45 +0000 |
---|---|---|
committer | Justus Winter <[email protected]> | 2017-04-04 16:48:51 +0000 |
commit | 6261611d3786f19fd84ccc79f45a89cadac518e8 (patch) | |
tree | 0587991351692d6849f2afefd44a869b529ddddd /tests/openpgp/decrypt-session-key.scm | |
parent | gpgscm: Simplify get-output-string operation. (diff) | |
download | gnupg-6261611d3786f19fd84ccc79f45a89cadac518e8.tar.gz gnupg-6261611d3786f19fd84ccc79f45a89cadac518e8.zip |
gpgscm: Fix copying values.
* tests/gpgscm/scheme.c (copy_value): New function.
(mk_tagged_value): Use new function.
(opexe_4): Likewise for OP_SAVE_FORCED.
--
Occasionally, we need to copy a value from one location in the storage
to another. Scheme objects are fine. Some primitive objects,
however, require finalization, usually to free resources.
For these values, we either make a copy or acquire a reference.
Fixes e.g. a double free if a delayed expression evaluating to a
string is forced.
Signed-off-by: Justus Winter <[email protected]>
Diffstat (limited to 'tests/openpgp/decrypt-session-key.scm')
0 files changed, 0 insertions, 0 deletions