mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
* win32/win32.c (cmdglob): use inline function.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47259 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
e698311038
commit
ccbeb0d6dc
1 changed files with 1 additions and 4 deletions
|
@ -1485,7 +1485,6 @@ static NtCmdLineElement **
|
|||
cmdglob(NtCmdLineElement *patt, NtCmdLineElement **tail, UINT cp)
|
||||
{
|
||||
char buffer[MAXPATHLEN], *buf = buffer;
|
||||
char *p;
|
||||
NtCmdLineElement **last = tail;
|
||||
int status;
|
||||
|
||||
|
@ -1494,9 +1493,7 @@ cmdglob(NtCmdLineElement *patt, NtCmdLineElement **tail, UINT cp)
|
|||
|
||||
strlcpy(buf, patt->str, patt->len + 1);
|
||||
buf[patt->len] = '\0';
|
||||
for (p = buf; *p; p = CharNextExA(cp, p, 0))
|
||||
if (*p == '\\')
|
||||
*p = '/';
|
||||
translate_char(buf, '\\', '/', cp);
|
||||
status = ruby_brace_glob(buf, 0, insert, (VALUE)&tail);
|
||||
if (buf != buffer)
|
||||
free(buf);
|
||||
|
|
Loading…
Reference in a new issue