Opened 16 years ago

Closed 15 years ago

Last modified 15 years ago

#5733 closed patch (fixed)

Mythtv-0.21-fixes backend crashes on AMD64 when starting a recording from an analog tuner

Reported by: jan.nijs@… Owned by: Janne Grunau
Priority: major Milestone: 0.22
Component: mythtv Version: 0.21-fixes
Severity: medium Keywords: segfault amd64 lzo easy
Cc: gnome42@… Ticket locked: no

Description

I have Mythtv running on an AMD64. After I migrated from a 32bit distro to a 64 bit distro, mythtv started crashing randomly, but always at the start of an analog recording.

The message and important part of the backtrace:

Program received signal SIGSEGV, Segmentation fault. [Switching to Thread 0x4b61b950 (LWP 18796)] 0x00007f3f306a81ac in _lzo1x_1_do_compress (in=0x226c400 "\017p\002", in_len=159759, out=0xa2e6d8 "", out_len=0x4b61adec,

wrkmem=0xb326f0) at minilzo.cpp:1613

1613 minilzo.cpp: Permission denied.

in minilzo.cpp

#0 0x00007f3f306a81ac in _lzo1x_1_do_compress (in=0x226c400 "\017p\002", in_len=159759, out=0xa2e6d8 "",

out_len=0x4b61adec, wrkmem=0xb326f0) at minilzo.cpp:1613

m_pos = (const unsigned char *) 0x1b601f702270270 <Address 0x1b601f702270270 out of bounds> m_off = 3308 m_len = 0 dindex = 2239 ip = (const unsigned char *) 0x2270f5c "\001þ" op = (unsigned char *) 0xa31e12 "]" in_end = (const unsigned char * const) 0x229340f "" ip_end = (const unsigned char * const) 0x2293402 "\037È\b" ii = (const unsigned char *) 0x2270f53 "\016" dict = (const unsigned char const) 0xb326f0

#1 0x00007f3f306a876e in lzo1x_1_compress (in=0x226c400 "\017p\002", in_len=159759, out=0xa2e6d8 "", out_len=0x4b61adec,

wrkmem=0xb326f0) at minilzo.cpp:1838

op = (unsigned char *) 0xa2e6d8 "" t = 0

#2 0x00007f3f30cebe9a in NuppelVideoRecorder::WriteVideo? (this=0xa2e570, frame=0x4b61aef0, skipsync=false, forcekey=true)

at NuppelVideoRecorder?.cpp:3099

r = 0 freecount = 31 tmp = 159759 out_len = 1064979 frameheader = {frametype = 83 'S', comptype = 65 'A', keyframe = 0 '\0', filters = 0 '\0', timecode = 7314285,

packetlength = 0}

raw = 0 compressthis = 1

For me the solution has been to upgrade the miniLZO library to the latest version. It fixes a number of issues with 64 bit platforms. Patch attached.

Attachments (1)

mythtv-lzo-crash-fix.patch (256.0 KB) - added by jan.nijs@… 16 years ago.

Download all attachments as: .zip

Change History (10)

Changed 16 years ago by jan.nijs@…

Attachment: mythtv-lzo-crash-fix.patch added

comment:1 Changed 16 years ago by Shane Shrybman

Cc: gnome42@… added

Thanks for the debugging and the patch Jan!

Isaac, this looks like a straight forward update of miniLZO from version 1.07 to 2.03. The patch applied cleanly and I've done some basic testing on 32bit and it seems fine.

Relatively urgent for analog, 64bit users.

comment:2 Changed 16 years ago by Dibblah

Keywords: easy added

comment:3 Changed 16 years ago by Dibblah

Owner: changed from Isaac Richards to Janne Grunau
Status: newassigned

comment:4 Changed 16 years ago by stuartm

Milestone: 0.21.10.22

comment:5 Changed 16 years ago by stuartm

Owner: changed from Janne Grunau to shane

comment:6 Changed 15 years ago by Janne Grunau

Owner: changed from shane to Janne Grunau
Status: assignedaccepted

comment:7 Changed 15 years ago by Janne Grunau

Resolution: fixed
Status: acceptedclosed

(In [21332]) syncs included minilzo copy from release 1.07 to 2.03. Fixes #5733

fixes random crash during startup of analog recordings on X86_32

comment:8 Changed 15 years ago by Janne Grunau

(In [21333]) forgot to add lzodefs.h in [21332]. Refs #5733

comment:9 Changed 15 years ago by Janne Grunau

(In [21334]) backports [21332] and [21333] from trunk, Refs #5733

syncs minilzo to 2.07, fix analog recording crashes on X86_64 patch by: jan [dot] nijs <ät> scarlet {dot} be

Note: See TracTickets for help on using tickets.