Mailing-List: contact cygwin-help AT sourceware DOT cygnus DOT com; run by ezmlm List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT sources DOT redhat DOT com Delivered-To: mailing list cygwin AT sources DOT redhat DOT com Message-ID: <911C684A29ACD311921800508B7293BA010A8AD1@cnmail> From: Mark Bradshaw To: "'Corinna Vinschen'" Subject: RE: SFTP server when / is c:\ Date: Wed, 25 Jul 2001 07:24:41 -0400 MIME-Version: 1.0 X-Mailer: Internet Mail Service (5.5.2653.19) Content-Type: text/plain; charset="iso-8859-1" Note-from-DJ: This may be spam Mhm. I like your version better! Thanks for patching my patch. I really appreciate all the work you do to make openssh (and others) run smoothly in cygwin. Here's a cyber pat on the back. Mark -----Original Message----- From: Corinna Vinschen [mailto:cygwin AT cygwin DOT com] Sent: Wednesday, July 25, 2001 5:22 AM To: cygwin Subject: Re: SFTP server when / is c:\ On Tue, Jul 24, 2001 at 04:44:44PM -0400, Mark Bradshaw wrote: > Sure thing. Here's the update diffs. I have patched your patch slightly to be less intrusive. Your patch to sftp-server.c changed the content of `path' which has been given as parameter. I changed the call to snprintf instead: diff -u -p -r1.34 sftp-server.c --- sftp-server.c 2001/07/04 03:32:33 1.34 +++ sftp-server.c 2001/07/25 08:44:31 @@ -756,8 +756,8 @@ process_readdir(void) stats = xrealloc(stats, nstats * sizeof(Stat)); } /* XXX OVERFLOW ? */ - snprintf(pathname, sizeof pathname, - "%s/%s", path, dp->d_name); + snprintf(pathname, sizeof pathname, "%s%s%s", path, + strcmp(path, "/") ? "/" : "", dp->d_name); if (lstat(pathname, &st) < 0) continue; stat_to_attrib(&st, &(stats[count].attrib)); I have send the patch to the openssh-unix-dev mailing list a few minutes ago. The Cygwin openssh-2.9p2-3 version containg your patch is on sourceware already and will show up on the mirrors at least tomorrow. Thanks for tracking this down and especially for providing a patch! Corinna -- Corinna Vinschen Please, send mails regarding Cygwin to Cygwin Developer mailto:cygwin AT cygwin DOT com Red Hat, Inc. -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Bug reporting: http://cygwin.com/bugs.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/ -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Bug reporting: http://cygwin.com/bugs.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/