summaryrefslogtreecommitdiffstats
path: root/libhb
diff options
context:
space:
mode:
authortiter <[email protected]>2006-04-21 20:22:33 +0000
committertiter <[email protected]>2006-04-21 20:22:33 +0000
commit1193f04a03e4684de5a64db3ed4a20058c00482f (patch)
treeb8719360e6c7552131fccafa4969c3412b25ddf9 /libhb
parentaa987aa416174c9ed106c968b8be566c1af1f2b7 (diff)
Fixed scanning of DVD folders
git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@67 b64f7644-9d1e-0410-96f1-a4d463321fa5
Diffstat (limited to 'libhb')
-rw-r--r--libhb/dvd.c14
1 files changed, 11 insertions, 3 deletions
diff --git a/libhb/dvd.c b/libhb/dvd.c
index 4c894a907..faa82b2e0 100644
--- a/libhb/dvd.c
+++ b/libhb/dvd.c
@@ -123,15 +123,23 @@ hb_title_t * hb_dvd_title_scan( hb_dvd_t * d, int t )
float duration_correction;
unsigned char unused[1024];
+ hb_log( "scan: scanning title %d", t );
+
title = hb_title_init( d->path, t );
if( DVDUDFVolumeInfo( d->reader, title->name, sizeof( title->name ),
unused, sizeof( unused ) ) )
{
- goto fail;
+ char * p_cur, * p_last = d->path;
+ for( p_cur = d->path; *p_cur; p_cur++ )
+ {
+ if( p_cur[0] == '/' && p_cur[1] )
+ {
+ p_last = &p_cur[1];
+ }
+ }
+ snprintf( title->name, sizeof( title->name ), "%s", p_last );
}
- hb_log( "scan: scanning title %d", t );
-
/* VTS which our title is in */
title->vts = d->vmg->tt_srpt->title[t-1].title_set_nr;