diff --git a/src/color-profile.cpp b/src/color-profile.cpp
index 42650b1704b15879361b2a0b45e2df37dd0e76ce..a562d756c7967c5d0abf7fcc111362db25384075 100644 (file)
--- a/src/color-profile.cpp
+++ b/src/color-profile.cpp
//# 3. Resolve the href according the docBase. This follows
// the w3c specs. All absolute and relative issues are considered
org::w3c::dom::URI cprofUri = docUri.resolve(hrefUri);
- gchar* fullname = (gchar *)cprofUri.getNativePath().c_str();
+ gchar* fullname = g_strdup((gchar *)cprofUri.getNativePath().c_str());
cprof->_clearProfile();
cprof->profHandle = cmsOpenProfileFromFile( fullname, "r" );
if ( cprof->profHandle ) {
#ifdef DEBUG_LCMS
DEBUG_MESSAGE( lcmsOne, "cmsOpenProfileFromFile( '%s'...) = %p", fullname, (void*)cprof->profHandle );
#endif // DEBUG_LCMS
-
+ g_free(fullname);
#endif // ENABLE_LCMS
}
}