From a2cd78a559ddced86fd35ab9334bcdf270826f2b Mon Sep 17 00:00:00 2001 From: nobu Date: Mon, 22 Jun 2015 00:21:34 +0000 Subject: [PATCH] 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 --- win32/win32.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/win32/win32.c b/win32/win32.c index 445a5c4bd8..b8563aad2c 100644 --- a/win32/win32.c +++ b/win32/win32.c @@ -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':')