1From 6b9438d746cec6e4e632d78c5244f4be6314d1c9 Mon Sep 17 00:00:00 2001
2From: Allen Winter <allen.winter@kdab.com>
3Date: Sun, 28 May 2017 12:51:10 -0400
4Subject: [PATCH] icaltypes.c - icalreqstattype_from_string(), copy the
5 reqstattype's debug string into its own memory in the ring buffer.
6
7Issue#253
8Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
9[Retrieved (and backported) from:
10https://github.com/libical/libical/commit/6b9438d746cec6e4e632d78c5244f4be6314d1c9]
11---
12 src/libical/icaltypes.c | 2 +-
13 1 file changed, 1 insertion(+), 1 deletion(-)
14
15diff --git a/src/libical/icaltypes.c b/src/libical/icaltypes.c
16index 70c50d29..85c33545 100644
17--- a/src/libical/icaltypes.c
18+++ b/src/libical/icaltypes.c
19@@ -140,7 +140,7 @@ struct icalreqstattype icalreqstattype_from_string(const char *str)
20
21   p2 = strchr(p1+1,';');
22   if (p2 != 0 && *p2 != 0){
23-    stat.debug = p2+1;
24+    stat.debug = icalmemory_tmp_copy(p2+1);
25   }
26
27   return stat;
28