diff options
author | Guillaume Emont <guillaume@fluendo.com> | 2008-12-11 12:32:03 +0000 |
---|---|---|
committer | Sebastian Dröge <slomo@circular-chaos.org> | 2008-12-11 12:32:03 +0000 |
commit | d477a37e7effb528d8d0f9888fa28c1ab2a4b89f (patch) | |
tree | f6d64c5a29807b1e78fbe5ebfd7572c38750ba1f | |
parent | 08736ec1aedfb6a0bdaf1eca5500f41548382a3f (diff) |
gst/typefind/gsttypefindfunctions.c: Add typefinders for MS Word files and OS X .DS_Store files to prevent them to be...
Original commit message from CVS:
Patch by: Guillaume Emont <guillaume at fluendo dot com>
* gst/typefind/gsttypefindfunctions.c: (plugin_init):
Add typefinders for MS Word files and OS X .DS_Store files to
prevent them to be recognized as MPEG files. Fixes bug #564098.
-rw-r--r-- | ChangeLog | 8 | ||||
-rw-r--r-- | gst/typefind/gsttypefindfunctions.c | 9 |
2 files changed, 17 insertions, 0 deletions
@@ -1,3 +1,11 @@ +2008-12-11 Sebastian Dröge <sebastian.droege@collabora.co.uk> + + Patch by: Guillaume Emont <guillaume at fluendo dot com> + + * gst/typefind/gsttypefindfunctions.c: (plugin_init): + Add typefinders for MS Word files and OS X .DS_Store files to + prevent them to be recognized as MPEG files. Fixes bug #564098. + 2008-12-11 Wim Taymans <wim.taymans@collabora.co.uk> * gst/playback/gstplaysink.c: (gen_audio_chain), diff --git a/gst/typefind/gsttypefindfunctions.c b/gst/typefind/gsttypefindfunctions.c index 686937f85..8e81fe6dc 100644 --- a/gst/typefind/gsttypefindfunctions.c +++ b/gst/typefind/gsttypefindfunctions.c @@ -3139,6 +3139,8 @@ plugin_init (GstPlugin * plugin) static gchar *imelody_exts[] = { "imy", "ime", "imelody", NULL }; static gchar *pdf_exts[] = { "pdf", NULL }; static gchar *mxf_exts[] = { "mxf", NULL }; + static gchar *msword_exts[] = { "doc", NULL }; + static gchar *dsstore_exts[] = { "DS_Store", NULL }; GST_DEBUG_CATEGORY_INIT (type_find_debug, "typefindfunctions", GST_DEBUG_FG_GREEN | GST_DEBUG_BG_RED, "generic type find functions"); @@ -3356,6 +3358,13 @@ plugin_init (GstPlugin * plugin) GST_RANK_SECONDARY, nsf_exts, "NESM\x1a", 5, GST_TYPE_FIND_MAXIMUM); TYPE_FIND_REGISTER_START_WITH (plugin, "application/pdf", GST_RANK_SECONDARY, pdf_exts, "%PDF-", 5, GST_TYPE_FIND_LIKELY); + TYPE_FIND_REGISTER_START_WITH (plugin, "application/msword", + GST_RANK_SECONDARY, msword_exts, "\320\317\021\340\241\261\032\341", 8, + GST_TYPE_FIND_LIKELY); + /* Mac OS X .DS_Store files tend to be taken for video/mpeg */ + TYPE_FIND_REGISTER_START_WITH (plugin, "application/octet-stream", + GST_RANK_SECONDARY, dsstore_exts, "\000\000\000\001Bud1", 8, + GST_TYPE_FIND_LIKELY); return TRUE; } |