[easytag] Fix id3v24_tag.c unused result warning, bug 699979
- From: David King <davidk src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [easytag] Fix id3v24_tag.c unused result warning, bug 699979
- Date: Thu, 9 May 2013 17:54:54 +0000 (UTC)
commit 661dab454a47390ff9e5d4d7b2a76f70961c6ba7
Author: Abhinav <abhijangda hotmail com>
Date: Thu May 9 23:10:26 2013 +0530
Fix id3v24_tag.c unused result warning, bug 699979
src/id3v24_tag.c | 12 ++++++++++--
1 files changed, 10 insertions(+), 2 deletions(-)
---
diff --git a/src/id3v24_tag.c b/src/id3v24_tag.c
index 21ec1fe..8e5bcb2 100644
--- a/src/id3v24_tag.c
+++ b/src/id3v24_tag.c
@@ -1484,8 +1484,16 @@ etag_write_tags (const gchar *filename,
// Write the ID3v2 tag
if (v2buf)
- write(fd, v2buf, v2size);
-
+ {
+ if (write (fd, v2buf, v2size) != v2size)
+ {
+ gchar *basename_utf8 = g_path_get_basename (filename_utf8);
+ Log_Print (LOG_ERROR, _("Cannot save tag of file '%s'"),
+ basename_utf8);
+ g_free (basename_utf8);
+ goto out;
+ }
+ }
// Write audio data
if (write(fd, ctx, ctxsize) != ctxsize)
{
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]