<?xml version='1.0' encoding='UTF-8'?><?xml-stylesheet href="http://www.blogger.com/styles/atom.css" type="text/css"?><feed xmlns='http://www.w3.org/2005/Atom' xmlns:openSearch='http://a9.com/-/spec/opensearchrss/1.0/'><id>tag:blogger.com,1999:blog-35024958.post993190014642551346..comments</id><updated>2010-06-10T08:30:02.310+10:00</updated><category term='templates'/><category term='static_assert'/><category term='threads'/><category term='timer'/><category term='decltype'/><category term='sfinae'/><category term='error_code'/><category term='ssl'/><category term='c++0x'/><category term='parallelism'/><category term='boost'/><category term='iostream'/><category term='c++'/><category term='timeout'/><category term='asio'/><category term='system_error'/><category term='bind'/><category term='hardware'/><category term='coroutines'/><title type='text'>Comments on Thinking Asynchronously in C++: Unbuffered socket iostreams</title><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://blog.think-async.com/feeds/993190014642551346/comments/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/35024958/993190014642551346/comments/default'/><link rel='alternate' type='text/html' href='http://blog.think-async.com/2007/01/unbuffered-socket-iostreams.html'/><author><name>chris</name><uri>http://www.blogger.com/profile/09159109667366328919</uri><email>noreply@blogger.com</email><gd:image xmlns:gd='http://schemas.google.com/g/2005' rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><generator version='7.00' uri='http://www.blogger.com'>Blogger</generator><openSearch:totalResults>5</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>25</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-35024958.post-2649413094395356445</id><published>2008-12-25T05:13:00.000+11:00</published><updated>2008-12-25T05:13:00.000+11:00</updated><title type='text'>Now, it would be nice if we could do async reads f...</title><content type='html'>Now, it would be nice if we could do async reads from socket iostreams.  The example is nice, but it only covers one-off sends and receives.  As far as I can tell, there is no way to get the iostream ease of use for reading from or writing to a socket unless you do it completely synchronously, since the underlying basic_socket_streambuf doesn't support anything but an asynchronous connect().&lt;BR/&gt;&lt;BR/&gt;Such functionality would also simplify one form of async_read(), it seems a bit strange that the first argument is something like an ip::tcp::socket and the second argument is a basic_stream_buf, which is itself a basic_socket.</content><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/35024958/993190014642551346/comments/default/2649413094395356445'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/35024958/993190014642551346/comments/default/2649413094395356445'/><link rel='alternate' type='text/html' href='http://blog.think-async.com/2007/01/unbuffered-socket-iostreams.html?showComment=1230142380000#c2649413094395356445' title=''/><author><name>ansonthegnome</name><uri>http://ansonthegnome.livejournal.com/</uri><email>noreply@blogger.com</email><gd:image xmlns:gd='http://schemas.google.com/g/2005' rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img1.blogblog.com/img/openid16-rounded.gif'/></author><thr:in-reply-to xmlns:thr='http://purl.org/syndication/thread/1.0' href='http://blog.think-async.com/2007/01/unbuffered-socket-iostreams.html' ref='tag:blogger.com,1999:blog-35024958.post-993190014642551346' source='http://www.blogger.com/feeds/35024958/posts/default/993190014642551346' type='text/html'/><gd:extendedProperty xmlns:gd='http://schemas.google.com/g/2005' name='blogger.itemClass' value='pid-900518863'/></entry><entry><id>tag:blogger.com,1999:blog-35024958.post-6041102936118578061</id><published>2008-02-29T23:32:00.000+11:00</published><updated>2008-02-29T23:32:00.000+11:00</updated><title type='text'>In fact, I did think about it and decided it shoul...</title><content type='html'>In fact, I did think about it and decided it should be on by default. Consequently my revised TR2 proposal (N2175) does specify that the stream should be tied to itself.&lt;BR/&gt;&lt;BR/&gt;However, it seems I forgot to actually implement it! :-/</content><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/35024958/993190014642551346/comments/default/6041102936118578061'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/35024958/993190014642551346/comments/default/6041102936118578061'/><link rel='alternate' type='text/html' href='http://blog.think-async.com/2007/01/unbuffered-socket-iostreams.html?showComment=1204288320000#c6041102936118578061' title=''/><author><name>chris</name><uri>http://www.blogger.com/profile/09159109667366328919</uri><email>noreply@blogger.com</email><gd:image xmlns:gd='http://schemas.google.com/g/2005' rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:in-reply-to xmlns:thr='http://purl.org/syndication/thread/1.0' href='http://blog.think-async.com/2007/01/unbuffered-socket-iostreams.html' ref='tag:blogger.com,1999:blog-35024958.post-993190014642551346' source='http://www.blogger.com/feeds/35024958/posts/default/993190014642551346' type='text/html'/><gd:extendedProperty xmlns:gd='http://schemas.google.com/g/2005' name='blogger.itemClass' value='pid-660467121'/></entry><entry><id>tag:blogger.com,1999:blog-35024958.post-1873780791525969923</id><published>2008-02-28T14:23:00.000+11:00</published><updated>2008-02-28T14:23:00.000+11:00</updated><title type='text'>Just a note to say that I had the same thought tha...</title><content type='html'>Just a note to say that I had the same thought that anonymous did, and think it's an entirely reasonable default for the stream to flush its write buffer when a read is attempted.  In fact, I was surprised that it didn't :)</content><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/35024958/993190014642551346/comments/default/1873780791525969923'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/35024958/993190014642551346/comments/default/1873780791525969923'/><link rel='alternate' type='text/html' href='http://blog.think-async.com/2007/01/unbuffered-socket-iostreams.html?showComment=1204168980000#c1873780791525969923' title=''/><author><name>jemfinch</name><uri>http://www.blogger.com/profile/03753146170165050792</uri><email>noreply@blogger.com</email><gd:image xmlns:gd='http://schemas.google.com/g/2005' rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:in-reply-to xmlns:thr='http://purl.org/syndication/thread/1.0' href='http://blog.think-async.com/2007/01/unbuffered-socket-iostreams.html' ref='tag:blogger.com,1999:blog-35024958.post-993190014642551346' source='http://www.blogger.com/feeds/35024958/posts/default/993190014642551346' type='text/html'/><gd:extendedProperty xmlns:gd='http://schemas.google.com/g/2005' name='blogger.itemClass' value='pid-1638322501'/></entry><entry><id>tag:blogger.com,1999:blog-35024958.post-2449220931123139280</id><published>2007-02-09T16:27:00.000+11:00</published><updated>2007-02-09T16:27:00.000+11:00</updated><title type='text'>Interesting idea, I didn't think of that. Using ti...</title><content type='html'>Interesting idea, I didn't think of that. Using tie() is not exactly the same as an unbuffered stream, but it does give the expected behaviour for request-response style protocols (like HTTP, SMTP etc). Perhaps it should also be set by default, hmmm... something to think about.</content><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/35024958/993190014642551346/comments/default/2449220931123139280'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/35024958/993190014642551346/comments/default/2449220931123139280'/><link rel='alternate' type='text/html' href='http://blog.think-async.com/2007/01/unbuffered-socket-iostreams.html?showComment=1170998820000#c2449220931123139280' title=''/><author><name>chris</name><uri>http://www.blogger.com/profile/09159109667366328919</uri><email>noreply@blogger.com</email><gd:image xmlns:gd='http://schemas.google.com/g/2005' rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:in-reply-to xmlns:thr='http://purl.org/syndication/thread/1.0' href='http://blog.think-async.com/2007/01/unbuffered-socket-iostreams.html' ref='tag:blogger.com,1999:blog-35024958.post-993190014642551346' source='http://www.blogger.com/feeds/35024958/posts/default/993190014642551346' type='text/html'/><gd:extendedProperty xmlns:gd='http://schemas.google.com/g/2005' name='blogger.itemClass' value='pid-660467121'/></entry><entry><id>tag:blogger.com,1999:blog-35024958.post-622482998912998352</id><published>2007-02-02T01:14:00.000+11:00</published><updated>2007-02-02T01:14:00.000+11:00</updated><title type='text'>Is it not possible to tie it to itself (or somethi...</title><content type='html'>Is it not possible to tie it to itself (or something similar) so that it automagically flushes on a read operation?</content><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/35024958/993190014642551346/comments/default/622482998912998352'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/35024958/993190014642551346/comments/default/622482998912998352'/><link rel='alternate' type='text/html' href='http://blog.think-async.com/2007/01/unbuffered-socket-iostreams.html?showComment=1170339240000#c622482998912998352' title=''/><author><name>Anonymous</name><email>noreply@blogger.com</email><gd:image xmlns:gd='http://schemas.google.com/g/2005' rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img1.blogblog.com/img/blank.gif'/></author><thr:in-reply-to xmlns:thr='http://purl.org/syndication/thread/1.0' href='http://blog.think-async.com/2007/01/unbuffered-socket-iostreams.html' ref='tag:blogger.com,1999:blog-35024958.post-993190014642551346' source='http://www.blogger.com/feeds/35024958/posts/default/993190014642551346' type='text/html'/><gd:extendedProperty xmlns:gd='http://schemas.google.com/g/2005' name='blogger.itemClass' value='pid-1503760847'/></entry></feed>
