Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 13776 - dvd::rip / transcode segfaults when in wrong directory
Summary: dvd::rip / transcode segfaults when in wrong directory
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: x86 Linux
: High normal (vote)
Assignee: Martin Schlemmer (RETIRED)
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2003-01-12 08:10 UTC by Tobias Klausmann (RETIRED)
Modified: 2003-02-04 19:42 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Tobias Klausmann (RETIRED) gentoo-dev 2003-01-12 08:10:18 UTC
I have emerged transcode, lame and divx4linux by the usual means. I've also
tested  various sets of optimization flags, they make no difference in this
issue. Transcode segfaults when in the same dir as the file(s) it works on.
Here's an example:

[root@hiro tmp]# pwd
/mnt/yt/movies/lola_rennt/tmp
[root@hiro tmp]# transcode -a 0 -x vob,null -i
/mnt/yt/movies//lola_rennt/vob/001 -w 1141,250,100 -b 128,0,0 -s 1.857
--a52_drc_off -V  -f 25 -Y 64,8,64,8 -B 12,10,8 -R 1 -y divx4,null -o /dev/null 
transcode v0.6.3.20021205 (C) 2001-2002 Thomas 
Comment 1 Tobias Klausmann (RETIRED) gentoo-dev 2003-01-12 08:10:18 UTC
I have emerged transcode, lame and divx4linux by the usual means. I've also
tested  various sets of optimization flags, they make no difference in this
issue. Transcode segfaults when in the same dir as the file(s) it works on.
Here's an example:

[root@hiro tmp]# pwd
/mnt/yt/movies/lola_rennt/tmp
[root@hiro tmp]# transcode -a 0 -x vob,null -i
/mnt/yt/movies//lola_rennt/vob/001 -w 1141,250,100 -b 128,0,0 -s 1.857
--a52_drc_off -V  -f 25 -Y 64,8,64,8 -B 12,10,8 -R 1 -y divx4,null -o /dev/null 
transcode v0.6.3.20021205 (C) 2001-2002 Thomas Östreich
libdvdread: Using libdvdcss version 1.2.4 for DVD access
libdvdread: Couldn't find device name.
libdvdread: Can't open file VIDEO_TS.IFO.
[transcode] auto-probing source /mnt/yt/movies//lola_rennt/vob/001 (ok)
[transcode] V: import format    | MPEG-2  (V=vob|A=null)
[transcode] V: AV demux/sync    | (1) sync AV at initial MPEG sequence
[transcode] V: import frame     | 720x576  1.25:1  encoded @ 4:3
[transcode] V: new aspect ratio | 640x480  1.33:1 (-B)
[transcode] V: clip frame (->)  | 624x352
[transcode] V: bits/pixel       | 0.208
[transcode] V: encoding fps     | 25.000
[transcode] V: multi-pass       | (mode=1) writing data (pass 1) to divx4.log
[transcode] V: Y'CbCr           | YV12/I420
[transcode] A: import format    | 0x2000  AC3          [48000,16,2]  384 kbps
[transcode] A: export           | disabled
[transcode] A: bytes per frame  | 7680 (7680.000000)
[transcode] A: adjustment       | 0@1000
[transcode] A: rescale stream   | 1.857
[transcode] V: IA32 accel mode  | 3dnow (3dnow mmxext mmx asm)
[import_null.so] v0.2.0 (2002-01-19) (video) null | (audio) null
[import_vob.so] v0.5.7 (2002-10-01) (video) MPEG-2 | (audio) MPEG/AC3/PCM |
(subtitle)
[export_null.so] v0.1.2 (2001-08-17) (video) null | (audio) null
[export_divx4.so] v0.3.7 (2002-10-10) (video) DivX 4.x/5.x | (audio) MPEG/AC3/PCM
[import_vob.so] tccat -i "/mnt/yt/movies//lola_rennt/vob/001" -t vob -d 0 -S 0 |
tcdemux -s 0x80 -x mpeg2 -S 0 -M 1 -d 0 | tcextract -t vob -a 0 -x mpeg2 -d 0 |
tcdecode -x mpeg2 -d 0 -y yv12
[export_divx4.so] DivX 5.x libraries detected.
Segmentation fault (core dumped)
[root@hiro tmp]# 

This works with various sets of flags (even down to none except the basic
necessities). An strace -f of it is pretty inconclusive to me, but I'm no coder
(I can supply a trace logfile if need be).

If I use transcode from somewhere else with the same absolute paths, it works:

[root@hiro tmp]# cd
[root@hiro root]# transcode -a 0 -x vob,null -i
/mnt/yt/movies//lola_rennt/vob/001 -w 1141,250,100 -b 128,0,0 -s 1.857
--a52_drc_off -V  -f 25 -Y 64,8,64,8 -B 12,10,8 -R 1 -y divx4,null -o /dev/null 
transcode v0.6.3.20021205 (C) 2001-2002 Thomas Östreich
libdvdread: Using libdvdcss version 1.2.4 for DVD access
libdvdread: Couldn't find device name.
libdvdread: Can't open file VIDEO_TS.IFO.
[transcode] auto-probing source /mnt/yt/movies//lola_rennt/vob/001 (ok)
[transcode] V: import format    | MPEG-2  (V=vob|A=null)
[transcode] V: AV demux/sync    | (1) sync AV at initial MPEG sequence
[transcode] V: import frame     | 720x576  1.25:1  encoded @ 4:3
[transcode] V: new aspect ratio | 640x480  1.33:1 (-B)
[transcode] V: clip frame (->)  | 624x352
[transcode] V: bits/pixel       | 0.208
[transcode] V: encoding fps     | 25.000
[transcode] V: multi-pass       | (mode=1) writing data (pass 1) to divx4.log
[transcode] V: Y'CbCr           | YV12/I420
[transcode] A: import format    | 0x2000  AC3          [48000,16,2]  384 kbps
[transcode] A: export           | disabled
[transcode] A: bytes per frame  | 7680 (7680.000000)
[transcode] A: adjustment       | 0@1000
[transcode] A: rescale stream   | 1.857
[transcode] V: IA32 accel mode  | 3dnow (3dnow mmxext mmx asm)
[import_null.so] v0.2.0 (2002-01-19) (video) null | (audio) null
[import_vob.so] v0.5.7 (2002-10-01) (video) MPEG-2 | (audio) MPEG/AC3/PCM |
(subtitle)
[export_null.so] v0.1.2 (2001-08-17) (video) null | (audio) null
[export_divx4.so] v0.3.7 (2002-10-10) (video) DivX 4.x/5.x | (audio) MPEG/AC3/PCM
[import_vob.so] tccat -i "/mnt/yt/movies//lola_rennt/vob/001" -t vob -d 0 -S 0 |
tcdemux -s 0x80 -x mpeg2 -S 0 -M 1 -d 0 | tcextract -t vob -a 0 -x mpeg2 -d 0 |
tcdecode -x mpeg2 -d 0 -y yv12
[export_divx4.so] DivX 5.x libraries detected.
encoding frames [000000-000029],  28.88 fps, EMT: 0:00:01, ( 0| 1| 9) 

This wouldn't be as bad if dvd:rip wouldnt explicitly change to the mentioned
directory when  encoding. I'll try changing dvd::rip to not cd'ing, but I don't
know if I succeed or if it helps.
Comment 2 Tobias Klausmann (RETIRED) gentoo-dev 2003-01-12 08:15:18 UTC
Lo and behold:

Changing /usr/lib/perl5/site_perl/5.8.0/Video/DVDRip/Title.pm at the lines 1790
and 2182 (removing the "cd") works for me.
Comment 3 Joern Reder 2003-01-12 10:21:11 UTC
This is most likely no dvd::rip or transcode bug, but a well known bug in the
Divx5 codec. Quoting form: http://www.exit1.org/dvdrip/doc/faq.cipp#faq11 :

This is an annoying bug in the Divx5 codec. It tries to create a file
c:\trace_b.txt, which fails if you work on a vfat filesystem, because this
filename is illegal under Windows.

Execute the following Perl one-liner as root (thanks to Christian Marillat) to
patch the codec library file (probably the location is different on your system):

   perl -pi -e 's|c:\\trace_b.txt|/dev/null\0\0\0\0\0|' \ 
        /usr/lib/libdivxencore.so 
Comment 4 Tobias Klausmann (RETIRED) gentoo-dev 2003-01-12 14:51:19 UTC
I've checked this with my installation and the one-liner fix indeed works. Maybe
it should be integrated into the divx4linux ebuild?
Comment 5 Martin Schlemmer (RETIRED) gentoo-dev 2003-01-18 13:49:30 UTC
Fixed in -r2, thanks.