diff options
author | Miguel Freitas <miguelfreitas@users.sourceforge.net> | 2001-11-29 12:05:06 +0000 |
---|---|---|
committer | Miguel Freitas <miguelfreitas@users.sourceforge.net> | 2001-11-29 12:05:06 +0000 |
commit | 61419199c58b41c792447374a47470ba50dcbb96 (patch) | |
tree | 61c7178f4e9b7c86b8e0e818d9b5dabb49e35ee8 | |
parent | 25d7fa77204140f8cb8323b200b45a0fefd9edad (diff) | |
download | xine-lib-61419199c58b41c792447374a47470ba50dcbb96.tar.gz xine-lib-61419199c58b41c792447374a47470ba50dcbb96.tar.bz2 |
w32 bugfix, dvd branching
CVS patchset: 1135
CVS date: 2001/11/29 12:05:06
-rw-r--r-- | src/input/input_dvd.c | 22 | ||||
-rw-r--r-- | src/libw32dll/DirectShow/DS_VideoDecoder.c | 6 |
2 files changed, 25 insertions, 3 deletions
diff --git a/src/input/input_dvd.c b/src/input/input_dvd.c index 09b04c2a0..d1e695fc7 100644 --- a/src/input/input_dvd.c +++ b/src/input/input_dvd.c @@ -17,7 +17,7 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA * - * $Id: input_dvd.c,v 1.36 2001/11/18 03:53:23 guenter Exp $ + * $Id: input_dvd.c,v 1.37 2001/11/29 12:05:06 miguelfreitas Exp $ */ #ifdef HAVE_CONFIG_H @@ -365,6 +365,24 @@ static int dvd_plugin_open (input_plugin_t *this_gen, char *mrl) { return 1 ; } +static int dvd_plugin_is_branch_possible(input_plugin_t *this_gen, char *nextmrl ) { + dvd_input_plugin_t *this = (dvd_input_plugin_t *) this_gen; + char *mrl; + + if (strncasecmp (nextmrl, "dvd://", 6)) + return 0; + + mrl = this->mrl; + + mrl += 6; + nextmrl += 6; + + if( strncasecmp (mrl, "VTS_", 4) || strncasecmp (nextmrl, "VTS_", 4) ) + return 0; + + return 1; +} + static off_t dvd_plugin_read (input_plugin_t *this_gen, char *buf, off_t nlen) { @@ -762,7 +780,7 @@ input_plugin_t *init_input_plugin (int iface, xine_t *xine) { this->input_plugin.get_mrl = dvd_plugin_get_mrl; this->input_plugin.get_autoplay_list = dvd_plugin_get_autoplay_list; this->input_plugin.get_optional_data = dvd_plugin_get_optional_data; - this->input_plugin.is_branch_possible= NULL; + this->input_plugin.is_branch_possible= dvd_plugin_is_branch_possible; this->device = config->register_string(config, "input.dvd_device", DVD, "path to your local dvd device file", diff --git a/src/libw32dll/DirectShow/DS_VideoDecoder.c b/src/libw32dll/DirectShow/DS_VideoDecoder.c index 91db9fc63..85f5817a8 100644 --- a/src/libw32dll/DirectShow/DS_VideoDecoder.c +++ b/src/libw32dll/DirectShow/DS_VideoDecoder.c @@ -141,7 +141,11 @@ DS_VideoDecoder * DS_VideoDecoder_Create(CodecInfo * info, BITMAPINFOHEADER * f this->m_pDS_Filter = DS_Filter_Create((const char*)info->dll, &info->guid, &this->m_sOurType, &this->m_sDestType); - + if( !this->m_pDS_Filter ) { + /* FIXME: memory leak */ + return NULL; + } + if (!flip) { this->m_sVhdr2->bmiHeader.biHeight *= -1; |