开发者

BASH named pipe locking up

开发者 https://www.devze.com 2023-01-24 08:08 出处:网络
I don\'t understand why this is happening.I\'ve been working with this same command for a long time and now, suddenly, it\'s started locking up.

I don't understand why this is happening. I've been working with this same command for a long time and now, suddenly, it's started locking up.

mkfifo ./pipe
echo "test" >./pipe

What can I do to stop this from locking u开发者_JAVA百科p?


Read from the FIFO.


It's not locked up. It's waiting for something to read from the pipe. Execute

cat < ./pipe

in another window, and it will print out the test string you put into the pipe, and then your echo will exit.


I was having the same problem, and the same... huh... thinking error...

I solved my problem here, and discovered An excellent article about named pipes I wanted to share with everybody wanting to use "rightly" named pies.

Don't forget to read the comments ;)

Enjoy !

0

精彩评论

暂无评论...
验证码 换一张
取 消