[mythtv] %DIR% variable does not expand properly in new EventCmdRecStarted

Chris Pinkham cpinkham at bc2va.org
Tue Dec 29 22:10:29 UTC 2009


* On Mon Dec 28, 2009 at 05:09:00PM -0500, Bryan Mayland wrote:
> I've tried setting a value for the excellent new EventCmdRecStarted 
> event, but the %DIR% variable does not expand properly.  It looks like 
> the file doesn't exist on the disk yet so it expands to:
> /GetPlaybackURL/UNABLE/TO/FIND/LOCAL/FILE/ON/hostname

You are correct, when the event fires, the recording file may not exist
yet.  I may be able to move the event to later in the recording startup
process, I made a note to check into this and see if I can fire the event
later.

> While I was looking at this with VB_FILE on, I've also noticed it checks 
> the paths for the "Default" storage group on every host for the file.  
> Shouldn't it only check the local storage group directories when looking 
> for a local file?

This is the normal StorageGroups search fallback code.  The event could
fire on any host, so the normal search is performed since the file could
be local on the recording backend, but remote to a remote frontend.

> libs/libmyth/programinfo.cpp:1725
> <  StorageGroup sgroup(storagegroup);
> >  StorageGroup sgroup(storagegroup, gContext->GetHostName());

We could make this more intelligent by putting another 'if' statement in
there.  I made a note to look at this, but if you want to test a patch and
submit a ticket, feel free to assign it to me (cpinkham).

--
Chris


More information about the mythtv-dev mailing list