From 8e7b63067585acd7a73629c5afd60731018b3247 Mon Sep 17 00:00:00 2001 From: Joaquim Date: Fri, 21 Jun 2024 16:33:57 +0100 Subject: [PATCH] Keep the segment headers on output. --- src/gmtsimplify.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/gmtsimplify.c b/src/gmtsimplify.c index 4d7dabb5b13..0ba803b99ea 100644 --- a/src/gmtsimplify.c +++ b/src/gmtsimplify.c @@ -386,6 +386,7 @@ EXTERN_MSC int GMT_gmtsimplify (void *V_API, int mode, void *args) { S[GMT_OUT]->data[col][row] = S[GMT_IN]->data[col][index[row]]; if (smode) S[GMT_OUT]->text[row] = strdup (S[GMT_IN]->text[row]); } + if (S[GMT_IN]->header) S[GMT_OUT]->header = strdup(S[GMT_IN]->header); seg_out++; /* Move on to next output segment */ ns_in++; /* Input segment with points */ if (np_out) ns_out++; /* Output segment with points */