bruno1505 / pyetv

Automatically exported from code.google.com/p/pyetv
BSD 3-Clause "New" or "Revised" License
0 stars 0 forks source link

Occasional crashes in Front Row caused by corrupted /tmp/screenshot.jpg #74

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
Sometimes when I press Menu to return from EyeTV back to Front Row, Front Row 
crashes.  This is usually accompanied by an incomplete screenshot for the 
recording preview, and a message in the syslog like:

Dec 21 22:27:05 media com.apple.launchd.peruser.501[225] 
(com.apple.RemoteUI[56331]): Job appears to have crashed: Bus error
Dec 21 22:27:07 media ReportCrash[56502]: Saved crash report for Front 
Row[56331] version 2.2.1 (2.2.1) to 
/Users/media/Library/Logs/DiagnosticReports/Front 
Row_2010-12-21-222707_media.crash

I traced this to the etv.py function GetPreviewImagePath(self), which instructs 
EyeTV via AppleScript to generate a screenshot into /tmp/screenshot.jpg.  
Sometimes this file is truncated, leading to the crash in Front Row.

Commenting out the if-statement and forcing it to always follow the else-code 
which pulls the tiff from the EyeTV package seems to prevent the crash, though 
it does stop the preview image from updating.

I haven't yet tried seeing if a small delay also prevents the screenshot.jpg 
file from being truncated.

PyeTV 2.5.1 on a MacMini4,1 running Mac OS X Server 10.6.5 and EyeTV 3.4.2 
(6181).

Original issue reported on code.google.com by debb...@icemoonprison.com on 21 Dec 2010 at 12:11

GoogleCodeExporter commented 8 years ago
Thanks for running this down. This is the most useful bug report I've ever 
gotten on this project!

I'm away from my computer for the holidays, but I'll look into it when i get 
back. In the meantime, you might try putting a try/except block zround the 
offending statement, since it appears to be a race condition.  That way, it'll 
work or fail gracefully. 

Original comment by jon.chri...@gmail.com on 22 Dec 2010 at 2:49