> Possible ways to avoid this:
> * have a mutex per descriptor in io_fflush [?]
>
>
> Does ruby have an OS agnostic mutex system [like macros]?

Does anybody see any drawbacks to adding a ruby mutex to every rb_io_t
and using it to surround buffer manipulations?
Thanks!
-=R