Commit ad4d355c authored by conrad's avatar conrad

oggzdump: fix handling of -n (broken in changeset:2012 and changeset:2026);

use new method of OGGZ_STOP_OK to return from oggz_run() and close after the
first non-bos packet


git-svn-id: http://svn.annodex.net/liboggz/trunk@2030 8158c8cd-e7e1-0310-9fa4-c5954c97daef
parent f82835c5
......@@ -320,19 +320,15 @@ filter_page (OGGZ * oggz, const ogg_page * og, long serialno, void * user_data)
return 0;
}
static int
ignore_packet (OGGZ * oggz, ogg_packet * op, long serialno, void * user_data)
{
return -1;
}
static int
read_new_packet (OGGZ * oggz, ogg_packet * op, long serialno, void * user_data)
{
oggz_set_read_callback (oggz, serialno, ignore_packet, NULL);
read_packet (oggz, op, serialno, user_data);
return -1;
if (op->b_o_s) {
read_packet (oggz, op, serialno, user_data);
return OGGZ_CONTINUE;
} else {
return OGGZ_STOP_OK;
}
}
static void
......
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