diff options
author | Kaz Kylheku <kaz@kylheku.com> | 2015-11-28 19:21:17 -0800 |
---|---|---|
committer | Kaz Kylheku <kaz@kylheku.com> | 2015-11-28 19:21:17 -0800 |
commit | 24b5694c9fe7437322e09929527d98c7bee1408a (patch) | |
tree | a2d7e349bca7acfea1a11c8465fee99117293479 /lib.c | |
parent | 8bd9d47e3c25bfd964bb6950362d169c49887b66 (diff) | |
download | txr-24b5694c9fe7437322e09929527d98c7bee1408a.tar.gz txr-24b5694c9fe7437322e09929527d98c7bee1408a.tar.bz2 txr-24b5694c9fe7437322e09929527d98c7bee1408a.zip |
Bugfix: destructive behavior in transpose.
* lib.c (transpose): This function turns an input list
into an argument list which ends up in an args structure,
which potentially destroys it to prevent spurious retention.
The list must be copied. We don't use copy-list because
the function supports vectors.
Diffstat (limited to 'lib.c')
-rw-r--r-- | lib.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -5377,7 +5377,7 @@ val transposev(struct args *list) val transpose(val list) { - args_decl_list(args, ARGS_MIN, list); + args_decl_list(args, ARGS_MIN, copy(list)); return make_like(transposev(args), list); } |