mirror of
git://git.gnupg.org/gnupg.git
synced 2025-01-03 12:11:33 +01:00
gpgscm: Avoid mutating integer.
* tests/gpgscm/scheme.c (opexe_5): Do not modify the integer in-place while printing an vector. Integer objects may be shared, so they must not be mutated. Signed-off-by: Justus Winter <justus@g10code.com>
This commit is contained in:
parent
b83903f59e
commit
f1dc34f502
@ -5181,7 +5181,7 @@ static pointer opexe_5(scheme *sc, enum scheme_opcodes op) {
|
||||
s_return(sc,sc->T);
|
||||
} else {
|
||||
pointer elem=vector_elem(vec,i);
|
||||
ivalue_unchecked(cdr(sc->args))=i+1;
|
||||
cdr(sc->args) = mk_integer(sc, i + 1);
|
||||
s_save(sc,OP_PVECFROM, sc->args, sc->NIL);
|
||||
sc->args=elem;
|
||||
if (i > 0)
|
||||
|
Loading…
x
Reference in New Issue
Block a user