Note that neither the subdir nor the p pointer can be NULL.
Signed-off-by: Francois Gouget fgouget@free.fr --- dlls/kernel32/tests/path.c | 2 +- dlls/kernel32/tests/volume.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/dlls/kernel32/tests/path.c b/dlls/kernel32/tests/path.c index f15cc09ee5e..60cd26dd603 100644 --- a/dlls/kernel32/tests/path.c +++ b/dlls/kernel32/tests/path.c @@ -130,7 +130,7 @@ static void test_ValidPathA(const CHAR *curdir, const CHAR *subdir, const CHAR * ok(! HAS_TRAIL_SLASH_A(curdirshort), "%s: GetShortPathNameA should not have a trailing \\n",errstr); /* build relative and absolute paths from inputs */ - if(lstrlenA(subdir)) { + if(*subdir) { sprintf(subpath,"%s\%s",subdir,filename); } else { lstrcpyA(subpath,filename); diff --git a/dlls/kernel32/tests/volume.c b/dlls/kernel32/tests/volume.c index 21a2b313e56..348ce1a76c5 100644 --- a/dlls/kernel32/tests/volume.c +++ b/dlls/kernel32/tests/volume.c @@ -83,7 +83,7 @@ static void test_query_dos_deviceA(void) if (ret && GetLastError() != ERROR_INSUFFICIENT_BUFFER) { p = buffer; for (;;) { - if (!strlen(p)) break; + if (!*p) break; ret2 = QueryDosDeviceA( p, buffer2, sizeof(buffer2) ); ok(ret2, "QueryDosDeviceA failed to return current mapping for %s, last error %u\n", p, GetLastError()); p += strlen(p) + 1;