Using os.execute crashes extension

Discuss your Lua playlist, album art and interface scripts.
Habtic
New Cone
New Cone
Posts: 2
Joined: 04 Jun 2014 23:15

Using os.execute crashes extension

Postby Habtic » 04 Jun 2014 23:21

As stated in the title I am currently trying to run an commandline tool from a vlc lua extension I've written.
Therefore I use os.execute(command).
After the lua script executes this command VLC will shortly after report, that the extension crashed and asks me to kill it.

Is there anything I have to consinder when using os.execute in VLC?
Can the execetuted commandline script crash the lua extension somehow?

Thanks in advance :)

fizzebu
Blank Cone
Blank Cone
Posts: 14
Joined: 24 May 2014 15:47

Re: Using os.execute crashes extension

Postby fizzebu » 07 Jun 2014 01:10

Is the extension maybe waiting for the commandline? You could try closing the commandline immediately after it opens, but that would only tell you that you can't use os.execute... so yeah :D

mederi
Big Cone-huna
Big Cone-huna
Posts: 1951
Joined: 15 Mar 2011 16:38
VLC version: 2.0.8
Operating System: Windows Vista/XP

Re: Using os.execute crashes extension

Postby mederi » 09 Jun 2014 10:59

If calculations of running extension take too long time (more than 10 seconds) or the extension waits too long time for completion of a Lua command, the following dialog appears:
Extension not responding! [x]
Extension 'extension' does not respond.
Do you want to kill it now?
[Yes]
There is a bug somewhere in the "killer of extensions" as it often causes crash of VLC.

Habtic
New Cone
New Cone
Posts: 2
Joined: 04 Jun 2014 23:15

Re: Using os.execute crashes extension

Postby Habtic » 09 Jun 2014 20:59

The problem is, the executed commandline command has to run for as long as it takes to finish.
But after some while VLC responds with the above mentioned message.
Is it possible to start a commandline and from within this commandline start a new one and kill the one that vlc created?

*EDIT*

This seems to be a viable solution :)


Return to “Scripting VLC in lua”

Who is online

Users browsing this forum: No registered users and 9 guests