- dtucker@cvs.openbsd.org 2005/10/31 06:15:04
[sftp.c] Fix sorting with "ls -1" command. From Robert Tsai, "looks right" deraadt@
This commit is contained in:
parent
788f212aed
commit
653b93be5d
|
@ -75,6 +75,9 @@
|
||||||
[clientloop.c packet.c serverloop.c session.c ssh-agent.c ssh-keygen.c]
|
[clientloop.c packet.c serverloop.c session.c ssh-agent.c ssh-keygen.c]
|
||||||
[ssh.c sshconnect.c sshconnect1.c sshd.c]
|
[ssh.c sshconnect.c sshconnect1.c sshd.c]
|
||||||
no need to escape single quotes in comments, no binary change
|
no need to escape single quotes in comments, no binary change
|
||||||
|
- dtucker@cvs.openbsd.org 2005/10/31 06:15:04
|
||||||
|
[sftp.c]
|
||||||
|
Fix sorting with "ls -1" command. From Robert Tsai, "looks right" deraadt@
|
||||||
|
|
||||||
20051102
|
20051102
|
||||||
- (dtucker) [openbsd-compat/bsd-misc.c] Bug #1108: fix broken strdup().
|
- (dtucker) [openbsd-compat/bsd-misc.c] Bug #1108: fix broken strdup().
|
||||||
|
@ -3208,4 +3211,4 @@
|
||||||
- (djm) Trim deprecated options from INSTALL. Mention UsePAM
|
- (djm) Trim deprecated options from INSTALL. Mention UsePAM
|
||||||
- (djm) Fix quote handling in sftp; Patch from admorten AT umich.edu
|
- (djm) Fix quote handling in sftp; Patch from admorten AT umich.edu
|
||||||
|
|
||||||
$Id: ChangeLog,v 1.3945 2005/11/05 04:14:59 djm Exp $
|
$Id: ChangeLog,v 1.3946 2005/11/05 04:15:23 djm Exp $
|
||||||
|
|
4
sftp.c
4
sftp.c
|
@ -16,7 +16,7 @@
|
||||||
|
|
||||||
#include "includes.h"
|
#include "includes.h"
|
||||||
|
|
||||||
RCSID("$OpenBSD: sftp.c,v 1.67 2005/09/13 23:40:07 djm Exp $");
|
RCSID("$OpenBSD: sftp.c,v 1.68 2005/10/31 06:15:04 dtucker Exp $");
|
||||||
|
|
||||||
#ifdef USE_LIBEDIT
|
#ifdef USE_LIBEDIT
|
||||||
#include <histedit.h>
|
#include <histedit.h>
|
||||||
|
@ -697,6 +697,8 @@ do_ls_dir(struct sftp_conn *conn, char *path, char *strip_path, int lflag)
|
||||||
}
|
}
|
||||||
|
|
||||||
if (lflag & SORT_FLAGS) {
|
if (lflag & SORT_FLAGS) {
|
||||||
|
for (n = 0; d[n] != NULL; n++)
|
||||||
|
; /* count entries */
|
||||||
sort_flag = lflag & (SORT_FLAGS|LS_REVERSE_SORT);
|
sort_flag = lflag & (SORT_FLAGS|LS_REVERSE_SORT);
|
||||||
qsort(d, n, sizeof(*d), sdirent_comp);
|
qsort(d, n, sizeof(*d), sdirent_comp);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue