summaryrefslogtreecommitdiffstats
authorRaghavendra D Prabhu <[email protected]>2011-04-10 16:11:59 (GMT)
committer Raghavendra D Prabhu <[email protected]>2011-04-10 16:11:59 (GMT)
commit2e14a7721eed972c942d13841a4b7b199ce99418 (patch) (side-by-side diff)
tree3401745d3c68312322044723816ae8c39f300e0e
parent9be7ca6fd73c99610bec6c2ec608e8f3ffd1fdd0 (diff)
downloadScripts-2e14a7721eed972c942d13841a4b7b199ce99418.zip
Scripts-2e14a7721eed972c942d13841a4b7b199ce99418.tar.gz
Scripts-2e14a7721eed972c942d13841a4b7b199ce99418.tar.bz2
fixes
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--functions1
-rwxr-xr-xmplayer11
2 files changed, 7 insertions, 5 deletions
diff --git a/functions b/functions
index 99aa69d..7c9bf1a 100644
--- a/functions
+++ b/functions
@@ -134,7 +134,6 @@ function cscope(){
[[ $? != 0 ]] && return 1
pushd $file:h
/usr/bin/cscope -d [email protected]
- popd
}
function cscore()
diff --git a/mplayer b/mplayer
index 0925a4f..726acea 100755
--- a/mplayer
+++ b/mplayer
@@ -163,14 +163,13 @@ if [[ ! -e $MPSOCKET ]] ;then
#notify-send "Mplayer" "mplayer starting up....."
fi
-exec &>>|/tmp/mplayer.log
+#exec &>>|/tmp/mplayer.log
pwdir=$(pwd)
pushd $HOME
-${=LOCK}/mplayer.$randnum /usr/bin/mplayer -$vo_map[$fixedvo] -msglevel all=4 -slave -idle -input file=$MPSOCKET -input conf=$HOME/.mplayer/input.conf.mine &!
popd
@@ -181,8 +180,12 @@ preplay
[[ $firstime == 1 ]] && sleep 3
if [[ $stdin == 1 ]];then
- #pecho "loadfile /dev/fd/0" /tmp/mplayer.fif
- /usr/bin/mplayer -
+ fd=$(readlink -f /dev/stdin)
+ exec 3<&0
+ exec 0</dev/tty
+ ${=LOCK}/mplayer.$randnum /usr/bin/mplayer -$vo_map[$fixedvo] -msglevel all=4 -slave -idle -input file=$MPSOCKET -input conf=$HOME/.mplayer/input.conf.mine &!
+ pecho "loadfile $fd " /tmp/mplayer.fif
+ #/usr/bin/mplayer -
exit 110
else
pecho "loadfile \"$FILE\" 2" $MPSOCKET