summaryrefslogtreecommitdiffstats
path: root/source/smbd/dir.c
diff options
context:
space:
mode:
authorTim Potter <tpot@samba.org>2000-02-03 23:08:24 +0000
committerTim Potter <tpot@samba.org>2000-02-03 23:08:24 +0000
commit176c405d2702a4245561ff56c8eac3c754a0dea3 (patch)
tree6d82ba6a996929720356e72c911c9e1fe09f7de6 /source/smbd/dir.c
parent8b26be1e82d329c9ea8a1d6a71e5e9f440eb93ac (diff)
downloadsamba-176c405d2702a4245561ff56c8eac3c754a0dea3.tar.gz
samba-176c405d2702a4245561ff56c8eac3c754a0dea3.tar.xz
samba-176c405d2702a4245561ff56c8eac3c754a0dea3.zip
Put back lots of missing calls to dos_to_unix(). Thanks to
aono@cc.osaka-kyoiku.ac.jp (Tomoki AONO)
Diffstat (limited to 'source/smbd/dir.c')
-rw-r--r--source/smbd/dir.c12
1 files changed, 8 insertions, 4 deletions
diff --git a/source/smbd/dir.c b/source/smbd/dir.c
index 32fc523541e..58b0061e19d 100644
--- a/source/smbd/dir.c
+++ b/source/smbd/dir.c
@@ -670,7 +670,7 @@ void *OpenDir(connection_struct *conn, char *name, BOOL use_veto)
{
Dir *dirp;
char *n;
- DIR *p = conn->vfs_ops.opendir(name);
+ DIR *p = conn->vfs_ops.opendir(dos_to_unix(name,False));
int used=0;
if (!p) return(NULL);
@@ -684,10 +684,14 @@ void *OpenDir(connection_struct *conn, char *name, BOOL use_veto)
while ((n = vfs_readdirname(conn, p)))
{
- int l = strlen(n)+1;
+ int l;
+ pstring zn;
+
+ pstrcpy(zn, unix_to_dos(n,True));
+ l = strlen(zn)+1;
/* If it's a vetoed file, pretend it doesn't even exist */
- if (use_veto && conn && IS_VETO_PATH(conn, n)) continue;
+ if (use_veto && conn && IS_VETO_PATH(conn, zn)) continue;
if (used + l > dirp->mallocsize) {
int s = MAX(used+l,used+2000);
@@ -701,7 +705,7 @@ void *OpenDir(connection_struct *conn, char *name, BOOL use_veto)
dirp->mallocsize = s;
dirp->current = dirp->data;
}
- pstrcpy(dirp->data+used,n);
+ pstrcpy(dirp->data+used,zn);
used += l;
dirp->numentries++;
}