Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.ruby > #7341
| From | Robert Klemme <shortcutter@googlemail.com> |
|---|---|
| Newsgroups | comp.lang.ruby |
| Subject | Re: How to flush stdin to popen3 without closing it? |
| Date | 2017-02-26 22:53 +0100 |
| Message-ID | <ehh12jF6dltU1@mid.individual.net> (permalink) |
| References | <8760jwkiyv.fsf@filestore.home.gustad.com> <ehgid3F3dm4U1@mid.individual.net> <87h93gd3s7.fsf@filestore.home.gustad.com> |
On 26.02.2017 22:46, Petter Gustad wrote: > Again, thanks! You're welcome! Just one more caveat, which might not apply in this case but a general advice for #popen and the likes: buffers between processes are limited. If you handle everything single threaded there is potential for deadlock. This will always happen if you send more data longer than the buffer size to the pipe and the other process will also send more than buffer size data. Then both are blocked on IO. Kind regards robert -- remember.guy do |as, often| as.you_can - without end http://blog.rubybestpractices.com/
Back to comp.lang.ruby | Previous | Next — Previous in thread | Find similar
How to flush stdin to popen3 without closing it? Petter Gustad <newsmailcomp6@gustad.com> - 2017-02-26 17:36 +0100
Re: How to flush stdin to popen3 without closing it? Robert Klemme <shortcutter@googlemail.com> - 2017-02-26 18:42 +0100
Re: How to flush stdin to popen3 without closing it? Petter Gustad <newsmailcomp6@gustad.com> - 2017-02-26 22:46 +0100
Re: How to flush stdin to popen3 without closing it? Robert Klemme <shortcutter@googlemail.com> - 2017-02-26 22:53 +0100
csiph-web