Change CoreConsole to use _get_wpgmptr
authorAndrew Stanton-Nurse <andrew@andrewnurse.net>
Thu, 15 Oct 2015 05:08:09 +0000 (22:08 -0700)
committerAndrew Stanton-Nurse <andrew@andrewnurse.net>
Thu, 15 Oct 2015 06:07:40 +0000 (23:07 -0700)
commit3bd624bb3f6679f5d4793787a082f707ad1a700e
treea8e83588c371256613f66b19ca923925d22c7924
parentc826885f85991fbeb1e99930f08ba4c3c4b8f9a8
Change CoreConsole to use _get_wpgmptr

The first value in argv only contains the string that was used to
launch the process. This means that when the CoreConsole-based
application is on the PATH, some invocations of it (most notably
those done from 'cmd') cause that value to be incomplete.

Changing to use _get_wpgmptr ensures that we always get the full
path to the executable, no matter how it is executed.

Fix #1771
src/coreclr/hosts/coreconsole/coreconsole.cpp