Re: SFTP create missing directories
Date: Wed, 13 Jun 2007 17:00:01 +0200
On Wednesday, 13. June 2007, James Housley wrote:
> On Jun 13, 2007, at 10:11 AM, Tom Regner wrote:
> > On Wednesday, 13. June 2007, James Housley wrote:
> >> On Jun 13, 2007, at 7:55 AM, Daniel Stenberg wrote:
> >>> On Wed, 13 Jun 2007, James Housley wrote:
> >>>>> http://curl.haxx.se/mail/lib-2007-06/0021.html
> >>>> I have integrated this patch into the code and can commit before
> >>> Fire away! ;-)
> >> Done
> > [...]
> > Cool!
> > I noticed you used my second patch version as basis for the
> > inclusion; do
> > you mind to explain why not version 3 ?
> I still think I would like a more solid way to do this, either with
> opendir() or [l]stat(). But, for now so this can make it into the
> release #2 was best. It was also getting very messy with the libssh2
> non-blocking capability to keep nesting the error loops.
> I also think we can use opendir() or [l]stat() in the
> create dirs code so we only have to do what is needed.
Definitly - I simply scratched my itch by reading the docs at
libssh2-includes for the minimum I needed to implement a
working version as fast as possible.
I now took a look at what is there, and FWIW I think we should use stat to
gather the necessary informations (possibly not up the path as it is now
done, but down the path, as it is likely that directories down the path
already exist), and attempt creation only after checking what
I think I can't help with anything concerning the state-machine, but I would
reimplement sftp_create_dirs accordingly if that's ok with you.
-- Tom Regner -- Jabber: tomte_at_tomsdiner.org http://www.tomsdiner.org
- application/pgp-signature attachment: This is a digitally signed message part.