www.libssh2.org | Daily snapshots | Mailing list archive | Docs | Examples

Archive Index This month's Index

Subject: Re: [libssh2] Non-blocking vs. default mode

Re: [libssh2] Non-blocking vs. default mode

From: James Housley <jim_at_thehousleys.net>
Date: Sun, 22 Apr 2007 17:52:40 -0400

On Apr 22, 2007, at 5:28 PM, Daniel Stenberg wrote:

> On Sun, 22 Apr 2007, James Housley wrote:
>
>>> 1) We have libssh2_channel_set_blocking() and it controls *ALL*
>>> functions to do blocking or non-blocking. This didn't work
>>> before, and I didn't take
>>> this route when I started to add *nb() functions.
>>
>> You are correct it did not work before, and creating *nb()
>> functions make it very easy to slowly migrate to our goal of
>> working fully in both blocking and non-blocking mode.
>
> I added the *nb() functions mostly to not change how the old
> blocking ones work. Even if the changes would only be subtle. I'm
> beginning to think I did the wrong choice.

[snip]

>
>> Or, the new function I proposed can be added so libssh2 just
>> figures it out for itself.
>
> I don't see in what situations libssh2 wouldn't know which mode to
> use/set.

I think maybe we should remove the *nb() functions and make the old
names just work. I would also like to keep old programs working in
all cases, as long as they didn't set non-blocking to true (since we
know that didn't work). But before proceeding I would like to wait a
while, April 29th, to allow others a chance to chime in.

Jim

--
/"\   ASCII Ribbon Campaign  .
\ / - NO HTML/RTF in e-mail  .
  X  - NO Word docs in e-mail .
/ \ -----------------------------------------------------------------
jeh@FreeBSD.org      http://www.FreeBSD.org     The Power to Serve
jim@TheHousleys.Net  http://www.TheHousleys.net
---------------------------------------------------------------------
In theory there is no difference between theory and practice.
In practice there is no similarity.
       -- From the "I wish I'd said that" archives.
-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
libssh2-devel mailing list
libssh2-devel_at_lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/libssh2-devel
Received on 2007-04-22

the libssh2 team