[easytag/wip/ogg-errors] Ignore Ogg EOF errors when fetching packets
- From: David King <davidk src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [easytag/wip/ogg-errors] Ignore Ogg EOF errors when fetching packets
- Date: Thu, 30 May 2013 21:57:57 +0000 (UTC)
commit 101b678251fd371aae4d5528524377f211850acd
Author: David King <amigadave amigadave com>
Date: Thu May 30 22:56:52 2013 +0100
Ignore Ogg EOF errors when fetching packets
Although this is nominally an error, it is not a failure if there are no
more packets in the stream.
src/misc.c | 2 +-
src/vcedit.c | 5 ++++-
2 files changed, 5 insertions(+), 2 deletions(-)
---
diff --git a/src/misc.c b/src/misc.c
index 4a1860f..df0cdb3 100644
--- a/src/misc.c
+++ b/src/misc.c
@@ -3113,7 +3113,7 @@ Load_File_Content (GtkWidget *entry)
gtk_list_store_clear(LoadFileContentListModel);
while ((size_read = g_input_stream_read (G_INPUT_STREAM (istream),
buffer, sizeof(buffer),
- NULL, &error) > 0))
+ NULL, &error)) > 0)
{
if (buffer[strlen(buffer)-1]=='\n')
buffer[strlen(buffer)-1]='\0';
diff --git a/src/vcedit.c b/src/vcedit.c
index d0befe2..24bc9f0 100644
--- a/src/vcedit.c
+++ b/src/vcedit.c
@@ -628,7 +628,10 @@ vcedit_write(vcedit_state *state, GFile *file, GError **error)
if (error == NULL || *error != NULL)
{
- goto cleanup;
+ if (!g_error_matches (*error, ET_OGG_ERROR, ET_OGG_ERROR_EOF))
+ {
+ goto cleanup;
+ }
}
streamout.e_o_s = 1;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]