aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--commands/command_divesite.cpp2
-rw-r--r--core/taxonomy.c2
2 files changed, 2 insertions, 2 deletions
diff --git a/commands/command_divesite.cpp b/commands/command_divesite.cpp
index 6f558d408..39e10e840 100644
--- a/commands/command_divesite.cpp
+++ b/commands/command_divesite.cpp
@@ -268,7 +268,7 @@ bool EditDiveSiteCountry::workToBeDone()
void EditDiveSiteCountry::redo()
{
QString old = taxonomy_get_country(&ds->taxonomy);
- taxonomy_set_country(&ds->taxonomy, copy_qstring(value), taxonomy_origin::GEOMANUAL);
+ taxonomy_set_country(&ds->taxonomy, qPrintable(value), taxonomy_origin::GEOMANUAL);
value = old;
emit diveListNotifier.diveSiteChanged(ds, LocationInformationModel::TAXONOMY); // Inform frontend of changed dive site.
}
diff --git a/core/taxonomy.c b/core/taxonomy.c
index 45989e6c7..15086d28d 100644
--- a/core/taxonomy.c
+++ b/core/taxonomy.c
@@ -105,7 +105,7 @@ void taxonomy_set_category(struct taxonomy_data *t, enum taxonomy_category categ
}
idx = t->nr++;
}
- t->category[idx].value = value;
+ t->category[idx].value = strdup(value);
t->category[idx].origin = origin;
t->category[idx].category = category;
}