changed to use g_set_error().
2008-08-17 Sven Neumann <sven@gimp.org> * plug-ins/file-psd/psd-util.c (psd_set_error): changed to use g_set_error(). svn path=/trunk/; revision=26618
This commit is contained in:

committed by
Sven Neumann

parent
1277bb4415
commit
3fa2cbe022
@ -1,7 +1,7 @@
|
|||||||
2008-08-17 Sven Neumann <sven@gimp.org>
|
2008-08-17 Sven Neumann <sven@gimp.org>
|
||||||
|
|
||||||
* plug-ins/file-psd/psd-util.c (psd_set_error): changed to use
|
* plug-ins/file-psd/psd-util.c (psd_set_error): changed to use
|
||||||
g_error_new_literal().
|
g_set_error().
|
||||||
|
|
||||||
2008-08-17 Sven Neumann <sven@gimp.org>
|
2008-08-17 Sven Neumann <sven@gimp.org>
|
||||||
|
|
||||||
|
@ -45,19 +45,15 @@ psd_set_error (const gboolean file_eof,
|
|||||||
const gint err_no,
|
const gint err_no,
|
||||||
GError **error)
|
GError **error)
|
||||||
{
|
{
|
||||||
/*
|
|
||||||
* Set error
|
|
||||||
*/
|
|
||||||
if (file_eof)
|
if (file_eof)
|
||||||
{
|
{
|
||||||
*error = g_error_new (G_FILE_ERROR, G_FILE_ERROR_FAILED,
|
g_set_error (error, G_FILE_ERROR, G_FILE_ERROR_FAILED,
|
||||||
_("Unexpected end of file"));
|
"%s", _("Unexpected end of file"));
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
*error = g_error_new_literal (G_FILE_ERROR,
|
g_set_error (error, G_FILE_ERROR, g_file_error_from_errno (err_no),
|
||||||
g_file_error_from_errno (err_no),
|
"%s", g_strerror (err_no));
|
||||||
g_strerror (err_no));
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return;
|
return;
|
||||||
|
Reference in New Issue
Block a user