The last character of the argument is chopped as if it was a quote.
gcc/ada/
PR ada/122367
* rtinit.c (__gnat_runtime_initialize) [__MINGW32__]: Fix detection
of quoted arguments.
int last;
int argc_expanded = 0;
TCHAR result [MAX_PATH];
+ int arglen;
int quoted;
__gnat_get_argw (GetCommandLineW (), &wargv, &wargc);
for (k=1; k<wargc; k++)
{
- quoted = (wargv[k][0] == _T('\''));
+ arglen = _tcslen (wargv[k]);
+ quoted = wargv[k][0] == _T('\'')
+ && arglen > 1
+ && wargv[k][arglen - 1] == _T('\'');
/* Check for wildcard expansion if the argument is not quoted. */
if (!quoted && __gnat_do_argv_expansion