summaryrefslogtreecommitdiff
path: root/ext
diff options
context:
space:
mode:
Diffstat (limited to 'ext')
-rw-r--r--ext/socket/socket.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/ext/socket/socket.c b/ext/socket/socket.c
index 93a8aacce30..4c0934a87bd 100644
--- a/ext/socket/socket.c
+++ b/ext/socket/socket.c
@@ -115,7 +115,7 @@ sock_new(class, fd)
#endif
fp->f2 = rb_fdopen(fd, "w");
fp->mode = FMODE_READWRITE;
- rb_io_unbuffered(fp);
+ rb_io_synchronized(fp);
return (VALUE)sock;
}