[xiph-commits] r15510 - in trunk/vorbis-tools: oggenc ogginfo
ivo at svn.xiph.org
ivo at svn.xiph.org
Wed Nov 5 13:47:53 PST 2008
Author: ivo
Date: 2008-11-05 13:47:53 -0800 (Wed, 05 Nov 2008)
New Revision: 15510
Modified:
trunk/vorbis-tools/oggenc/encode.c
trunk/vorbis-tools/oggenc/lyrics.c
trunk/vorbis-tools/ogginfo/ogginfo2.c
Log:
* fix leaking strings on error
* have skeleton clean up after itself
* recognize old FLAC mapping
Patches by ogg.k.ogg.k
Modified: trunk/vorbis-tools/oggenc/encode.c
===================================================================
--- trunk/vorbis-tools/oggenc/encode.c 2008-11-05 20:49:55 UTC (rev 15509)
+++ trunk/vorbis-tools/oggenc/encode.c 2008-11-05 21:47:53 UTC (rev 15510)
@@ -676,6 +676,9 @@
}
#endif
+ if (opt->with_skeleton)
+ ogg_stream_clear(&so);
+
ogg_stream_clear(&os);
vorbis_block_clear(&vb);
Modified: trunk/vorbis-tools/oggenc/lyrics.c
===================================================================
--- trunk/vorbis-tools/oggenc/lyrics.c 2008-11-05 20:49:55 UTC (rev 15509)
+++ trunk/vorbis-tools/oggenc/lyrics.c 2008-11-05 21:47:53 UTC (rev 15510)
@@ -67,15 +67,17 @@
return ret;
}
- len = strlen(utf8);
lyrics->lyrics = (oe_lyrics_item*)realloc(lyrics->lyrics, (lyrics->count+1)*sizeof(oe_lyrics_item));
if (!lyrics->lyrics) {
+ free(utf8);
fprintf(stderr, _("Out of memory\n"));
return -1;
}
+ len = strlen(utf8);
ret=kate_text_validate(kate_utf8,utf8,len+1);
if (ret<0) {
fprintf(stderr,_("WARNING: subtitle %s is not valid UTF-8\n"),utf8);
+ free(utf8);
}
else {
/* kill off trailing \n characters */
Modified: trunk/vorbis-tools/ogginfo/ogginfo2.c
===================================================================
--- trunk/vorbis-tools/ogginfo/ogginfo2.c 2008-11-05 20:49:55 UTC (rev 15509)
+++ trunk/vorbis-tools/ogginfo/ogginfo2.c 2008-11-05 21:47:53 UTC (rev 15510)
@@ -1056,6 +1056,8 @@
other_start(stream, "MIDI");
else if(packet.bytes >= 5 && memcmp(packet.packet, "\177FLAC", 5)==0)
other_start(stream, "FLAC");
+ else if(packet.bytes == 4 && memcmp(packet.packet, "fLaC", 4)==0)
+ other_start(stream, "FLAC (legacy)");
else if(packet.bytes >= 8 && memcmp(packet.packet, "Speex ", 8)==0)
other_start(stream, "speex");
else if(packet.bytes >= 8 && memcmp(packet.packet, "fishead\0", 8)==0)
@@ -1063,7 +1065,7 @@
else if(packet.bytes >= 5 && memcmp(packet.packet, "BBCD\0", 5)==0)
other_start(stream, "dirac");
else if(packet.bytes >= 8 && memcmp(packet.packet, "KW-DIRAC", 8)==0)
- other_start(stream, "dirac (old style)");
+ other_start(stream, "dirac (legacy)");
else if(packet.bytes >= 8 && memcmp(packet.packet, "\x80kate\0\0\0", 8)==0)
kate_start(stream);
else
More information about the commits
mailing list