Displaying 3 results from an estimated 3 matches for "path_strip".
Did you mean:
path_str
2003 Oct 13
1
Problem in sftp 'ls' command output
...idth = ws.ws_col;
columns = width / (m + 2);
columns = MAX(columns, 1);
colspace = width / columns;
}
--------
which aims to compute the column width and column spacing.
But when printing, a few lines below, we perform :
--------
tmp = path_append(path, d[n]->filename);
fname = path_strip(tmp, strip_path);
xfree(tmp);
if (lflag & LONG_VIEW) {
/* irrelevant code */
} else {
printf("%-*s", colspace, fname);
if (c >= columns) {
printf("\n");
c = 1;
} else
c++;
}
--------
What it boils down is that column width and spacing are computed on
f...
2007 Dec 12
0
Revisiting sftp tab completion patch
...eof(g));
+ if (remote != LOCAL) {
+ tmp = make_absolute(tmp, remote_path);
+ remote_glob(conn, tmp, 0, NULL, &g);
+ } else
+ glob(tmp, GLOB_DOOFFS, NULL, &g);
+
+ xfree(tmp);
+
+ if (g.gl_matchc == 0)
+ return (0);
+
+ tmp2 = complete_ambiguous(file, g.gl_pathv, g.gl_matchc);
+ tmp = path_strip(tmp2, remote_path);
+ xfree(tmp2);
+
+ if (g.gl_matchc > 1) {
+ char *pwd = strrchr(g.gl_pathv[0], '/');
+ u_int len = 0;
+
+ if (pwd != NULL)
+ len = strlen(g.gl_pathv[0]) - strlen(pwd) + 1;
+
+ complete_display(g.gl_pathv, len);
+ }
+
+ globfree(&g);
+ if (tmp != NULL) {
+ i...
2008 Jul 21
2
sftp needs a long time for sending a filelist
Hello all
Im using sftp 1:4.7p1-8ubuntu1.2
in a batchjob
Ive noticed that sftp needs a long time for sending a filelist.
The timespan increases exponential if many files are on the
remoteserver.
for example "ls -la *.txt" needs 10 seconds for 2000 files
but needs 50 seconds for 4000 files.
For 150.000 Files i have to wait 15 minutes for example
but the