<div dir="ltr">So this is it, a mechanism that waits for external fd:s? I.e. it adds an external fd to Gambit's select() call in the Scheduler, and then returns when there's data (or one can write)?<br><br>So for X external fd:s, one spawns X threads and calls port-wait-for-input with the port as parameter, and the port in turn is the result of fd->port?<br>
<br>Mikael<br><br><div class="gmail_quote">2008/9/3 Christian Jaeger <span dir="ltr"><<a href="mailto:christian@pflanze.mine.nu">christian@pflanze.mine.nu</a>></span><br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<div class="Ih2E3d">Christian Jaeger wrote:<br>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
Wait, I think I get what you want: you want to block your Gambit thread just as in a read or write operation but not actually carry out any read or write, correct? Just kind of peek-char that doesn't read into a buffer etc.; or basically, you want that this blocks until there is data to be read or there is the possibility to write data (pardon my shell syntax):<br>

<br>
({read,write}-subu8vector (u8vector) 0 0 port)<br>
<br>
That's a question for Marc I guess.<br>
  <br>
</blockquote>
<br></div>
Ok it didn't let me calm so... check out:<br>
<br>
<a href="http://scheme.mine.nu/gambit/experimental/wait-for-io/" target="_blank">http://scheme.mine.nu/gambit/experimental/wait-for-io/</a><br>
<br>
(git clone <a href="http://scheme.mine.nu/gambit/experimental/wait-for-io/.git" target="_blank">http://scheme.mine.nu/gambit/experimental/wait-for-io/.git</a>)<br><font color="#888888">
<br>
Christian.<br>
<br>
</font></blockquote></div><br></div>