mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
win32.c: use numberof
* win32/win32.c (open_dir_handle): use numberof() macro. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@50992 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
2431ad55b6
commit
a2cd78a559
1 changed files with 1 additions and 1 deletions
|
@ -1845,7 +1845,7 @@ open_dir_handle(const WCHAR *filename, WIN32_FIND_DATAW *fd)
|
|||
// Create the search pattern
|
||||
//
|
||||
len = lstrlenW(filename);
|
||||
scanname = ALLOCV_N(WCHAR, v, len + sizeof(wildcard) / sizeof(WCHAR));
|
||||
scanname = ALLOCV_N(WCHAR, v, len + numberof(wildcard));
|
||||
lstrcpyW(scanname, filename);
|
||||
p = CharPrevW(scanname, scanname + len);
|
||||
if (*p == L'/' || *p == L'\\' || *p == L':')
|
||||
|
|
Loading…
Reference in a new issue