Hi, This makes Wine pass the kernel directory conformance test without failures. -Hans Changelog: - Reject wildcards in directory names
Index: files/directory.c =================================================================== RCS file: /home/wine/wine/files/directory.c,v retrieving revision 1.70 diff -u -r1.70 directory.c --- files/directory.c 15 Nov 2003 00:13:21 -0000 1.70 +++ files/directory.c 17 Nov 2003 14:03:55 -0000 @@ -529,6 +529,12 @@ return FALSE; } + if (strchrW(path, '?') || strchrW(path, '*')) + { + SetLastError(ERROR_INVALID_NAME); + return FALSE; + } + TRACE_(file)("(%s,%p)\n", debugstr_w(path), lpsecattribs ); if (DOSFS_GetDevice( path )) @@ -575,6 +581,12 @@ return FALSE; } + if (strchr(path, '?') || strchr(path, '*')) + { + SetLastError(ERROR_INVALID_NAME); + return FALSE; + } + if (RtlCreateUnicodeStringFromAsciiz(&pathW, path)) { ret = CreateDirectoryW(pathW.Buffer, lpsecattribs); @@ -628,6 +640,12 @@ return FALSE; } + if (strchrW(path, '?') || strchrW(path, '*')) + { + SetLastError(ERROR_INVALID_NAME); + return FALSE; + } + TRACE_(file)("%s\n", debugstr_w(path)); if (DOSFS_GetDevice( path )) @@ -660,6 +678,12 @@ return FALSE; } + if (strchr(path, '?') || strchr(path, '*')) + { + SetLastError(ERROR_INVALID_NAME); + return FALSE; + } + if (RtlCreateUnicodeStringFromAsciiz(&pathW, path)) { ret = RemoveDirectoryW(pathW.Buffer);