summaryrefslogtreecommitdiffstats
path: root/src/color-profile.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/color-profile.cpp')
-rw-r--r--src/color-profile.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/color-profile.cpp b/src/color-profile.cpp
index b18112ece..2736b9a3b 100644
--- a/src/color-profile.cpp
+++ b/src/color-profile.cpp
@@ -922,7 +922,7 @@ Glib::ustring getNameFromProfile(cmsHPROFILE profile)
}
nameStr = Glib::ustring(data.begin(), data.end());
}
- if (nameStr.empty()) {
+ if (nameStr.empty() || !g_utf8_validate(nameStr.c_str(), -1, NULL)) {
nameStr = _("(invalid UTF-8 string)");
}
#endif