From 6e00de7a1d3d5f9fa9bcc40db119fcb8602165c9 Mon Sep 17 00:00:00 2001 From: Andrew Tridgell Date: Fri, 21 Aug 1998 05:58:57 +0000 Subject: [PATCH] fixed a bug in trans2_qfilepathinfo() where we used the length of the basename of a file but the whole file name. silly error. --- source/smbd/trans2.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/source/smbd/trans2.c b/source/smbd/trans2.c index 27892827716..190910bd97f 100644 --- a/source/smbd/trans2.c +++ b/source/smbd/trans2.c @@ -1251,6 +1251,9 @@ static int call_trans2qfilepathinfo(connection_struct *conn, mode = dos_mode(conn,fname,&sbuf); size = sbuf.st_size; if (mode & aDIR) size = 0; + + /* from now on we only want the part after the / */ + fname = p; params = *pparams = Realloc(*pparams,2); bzero(params,2); data_size = 1024; @@ -1399,6 +1402,7 @@ static int call_trans2qfilepathinfo(connection_struct *conn, SIVAL(pdata,20,l); pstrcpy(pdata+24,fname); break; + default: return(ERROR(ERRDOS,ERRunknownlevel)); }