Commit d336a49a authored by Sven Neumann's avatar Sven Neumann Committed by Sven Neumann
Browse files

return early if called for an internal data object. Fixes bug #172581.

2005-04-04  Sven Neumann  <sven@gimp.org>

	* app/core/gimpdata.c (gimp_data_create_filename): return early if
	called for an internal data object. Fixes bug #172581.
parent caf4ff87
2005-04-04 Sven Neumann <sven@gimp.org>
* app/core/gimpdata.c (gimp_data_create_filename): return early if
called for an internal data object. Fixes bug #172581.
2005-04-04 Sven Neumann <sven@gimp.org>
* plug-ins/common/deinterlace.c (deinterlace): fixed boundary
......
......@@ -402,18 +402,30 @@ void
gimp_data_create_filename (GimpData *data,
const gchar *dest_dir)
{
gchar *safename;
gchar *filename;
gchar *fullpath;
gint i;
gint unum = 1;
gchar *safename;
gchar *filename;
gchar *fullpath;
gint i;
gint unum = 1;
GError *error = NULL;
g_return_if_fail (GIMP_IS_DATA (data));
g_return_if_fail (dest_dir != NULL);
g_return_if_fail (g_path_is_absolute (dest_dir));
if (data->internal)
return;
safename = g_filename_from_utf8 (gimp_object_get_name (GIMP_OBJECT (data)),
-1, NULL, NULL, NULL);
-1, NULL, NULL, &error);
if (! safename)
{
g_warning ("gimp_data_create_filename:\n"
"g_filename_from_utf8() failed for '%s': %s",
gimp_object_get_name (GIMP_OBJECT (data)), error->message);
g_error_free (error);
return;
}
if (safename[0] == '.')
safename[0] = '-';
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment