diff options
author | GZNGET FOSS Team <opensource@gznianguan.com> | 2017-11-15 09:43:58 +0100 |
---|---|---|
committer | GZNGET FOSS Team <opensource@gznianguan.com> | 2017-11-15 09:43:58 +0100 |
commit | d1b24f24e50a2fadabc4cbf392dc6ac0d988ee64 (patch) | |
tree | 00ddf81dabb11dfe011589d604211eced3c74ba0 /bin | |
parent | 9a558c3b5a39dc26ad093ca2cddc3d930601a321 (diff) | |
download | arctica-mediaplayer-d1b24f24e50a2fadabc4cbf392dc6ac0d988ee64.tar.gz arctica-mediaplayer-d1b24f24e50a2fadabc4cbf392dc6ac0d988ee64.tar.bz2 arctica-mediaplayer-d1b24f24e50a2fadabc4cbf392dc6ac0d988ee64.zip |
Diffstat (limited to 'bin')
-rwxr-xr-x | bin/arctica-mediaplayer-overlay | 17 |
1 files changed, 8 insertions, 9 deletions
diff --git a/bin/arctica-mediaplayer-overlay b/bin/arctica-mediaplayer-overlay index 309e07f..020e959 100755 --- a/bin/arctica-mediaplayer-overlay +++ b/bin/arctica-mediaplayer-overlay @@ -1,5 +1,4 @@ #!/usr/bin/perl -X -T - ################################################################################ # _____ _ # |_ _| |_ ___ @@ -79,7 +78,7 @@ my $fmedia_port; if ($ENV{'TEKI_FMEDIA_PORT'} =~ /^(\d{1,5})$/) { $fmedia_port = $1; } else { - die; + BugOUT(0,"?"); } @@ -98,17 +97,17 @@ my $rwid; if (@ARGV[2] =~ /^([a-zA-Z0-9]*)$/) { $sock_id = $1; BugOUT(8,"SOC:\t$sock_id"); -} else {die("YOU SOCK!");} +} else {BugOUT(0,"YOU SOCK!");} if (@ARGV[3] =~ /^([a-zA-Z0-9]*)$/) { $tmplnkid = $1; BugOUT(8,"TMPLNKID:\t$tmplnkid"); -} else {die("YOU SOCK!");} +} else {BugOUT(0,"YOU SOCK!");} if (@ARGV[4] =~ /^([a-zA-Z0-9]{5,})$/) { $rwid = $1; BugOUT(8,"TMPLNKID:\t$tmplnkid"); -} else {die("YOU SOCK!");} +} else {BugOUT(0,"YOU SOCK!");} #print "YAY WE GOT IT: $tmplnkid\n"; my $TeKi; @@ -124,7 +123,7 @@ $TeKi = Arctica::Core::JABus::Socket->new($ACO,{ }, hooks => { on_ready => sub {my_ready($app_id,$ttid);}, - on_client_errhup => sub {die("\tLOST CONN!\n");}, + on_client_errhup => sub {BugOUT(0,"\tLOST CONN!\n");}, }, }); @@ -135,7 +134,7 @@ $TeKi = Arctica::Core::JABus::Socket->new($ACO,{ unlink($SlaveFIFO); } mkfifo($SlaveFIFO, 0700); - unless (-x '/usr/bin/mplayer') {die('NO /usr/bin/mplayer ?!');} + unless (-x '/usr/bin/mplayer') {BugOUT(0,'NO /usr/bin/mplayer ?!');} my $pid = open(my $mpFH,"-|",'/usr/bin/mplayer','-slave','-input' ,"file=$SlaveFIFO", '-vo',$MPVO,'-zoom','-framedrop','-fs','-wid',$rwid,'-volume','100', '-identify','-idle','-nolirc','-ss','1', "http://localhost:$fmedia_port/$tmplnkid.lnk","2>&1"); # my $pid = open(my $mpFH,"-|",'/usr/bin/mplayer','-slave','-input' ,"file=$SlaveFIFO", '-vo',$MPVO,'-zoom','-framedrop','-fs','-wid',$rwid,'-volume','100', '-identify','-idle','-nolirc','-ss','1', "/tmp/test.mp4","2>&1"); @@ -144,8 +143,8 @@ my $pid = open(my $mpFH,"-|",'/usr/bin/mplayer','-slave','-input' ,"file=$Sl my $timeout = Glib::Timeout->add(250, sub { #print "\tTime:\t",time,"\n\tLast:\t$lastcontact\n"; - if ($lastcontact < (time-1)) { - die("We're an orphan?"); + if ($lastcontact < (time-3)) { + BugOUT(0,"We're an orphan?"); } return 1; }); |