aboutsummaryrefslogtreecommitdiff
path: root/libcrystfel
diff options
context:
space:
mode:
authorThomas White <taw@physics.org>2019-02-28 16:57:13 +0100
committerThomas White <taw@physics.org>2019-03-01 14:09:37 +0100
commit77d9027f10488a7ccedc22782e06a7e61ee603b3 (patch)
tree0698e7881ee1ce6f77e9b48bc3005c85b4507b37 /libcrystfel
parent2ef84f8419beee133ba72d7c74966b83d3e6471d (diff)
crystal_copy(): Make new copy of notes if non-NULL
Diffstat (limited to 'libcrystfel')
-rw-r--r--libcrystfel/src/crystal.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/libcrystfel/src/crystal.c b/libcrystfel/src/crystal.c
index 6ac3b71e..66a8e19c 100644
--- a/libcrystfel/src/crystal.c
+++ b/libcrystfel/src/crystal.c
@@ -131,6 +131,7 @@ Crystal *crystal_copy(const Crystal *cryst)
if ( c == NULL ) return NULL;
memcpy(c, cryst, sizeof(Crystal));
+ if ( c->notes != NULL ) c->notes = strdup(c->notes);
return c;
}