[easytag] Fix et_core.c unused result warnings, bug 699979
- From: David King <davidk src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [easytag] Fix et_core.c unused result warnings, bug 699979
- Date: Thu, 9 May 2013 18:56:24 +0000 (UTC)
commit 134da63109b26840b8979ec4b3567878b5ba5b9c
Author: Abhinav <abhijangda hotmail com>
Date: Thu May 9 23:35:21 2013 +0530
Fix et_core.c unused result warnings, bug 699979
src/et_core.c | 7 ++++++-
src/log.c | 2 +-
2 files changed, 7 insertions(+), 2 deletions(-)
---
diff --git a/src/et_core.c b/src/et_core.c
index ec5d837..1493392 100644
--- a/src/et_core.c
+++ b/src/et_core.c
@@ -3857,7 +3857,12 @@ gboolean ET_Save_File_Tag_To_HD (ET_File *ETFile)
{
#ifndef G_OS_WIN32
chmod(cur_filename,statbuf.st_mode & (S_IRWXU|S_IRWXG|S_IRWXO));
- chown(cur_filename,statbuf.st_uid,statbuf.st_gid);
+ if (chown (cur_filename, statbuf.st_uid, statbuf.st_gid) == -1)
+ {
+ Log_Print (LOG_ERROR,
+ _("Cannot change the permissions of file '%s' (%s)"),
+ cur_filename, g_strerror (errno));
+ }
#endif /* !G_OS_WIN32 */
if (PRESERVE_MODIFICATION_TIME)
{
diff --git a/src/log.c b/src/log.c
index c8aee7c..14f7f2e 100644
--- a/src/log.c
+++ b/src/log.c
@@ -330,7 +330,7 @@ void Log_Print (Log_Error_Type error_type, gchar const *format, ...)
gchar *data = g_strdup_printf("%s %s\n",time,string);
if (fwrite (data, strlen (data), 1, file) != 1)
{
- //To avoid recursion of Log_Print, using g_critical
+ /* To avoid recursion of Log_Print. */
g_critical ("Error writing to the log file '%s'", file_path);
g_free (data);
g_free (time);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]