3 ms·
It seems the getenv_s and GetEnvironmentVariable API functions are 100% equivalent; the API is only slightly different. When you don’t know the length of the v
by Const-me 3y ago
It seems the getenv_s and GetEnvironmentVariable API functions are 100% equivalent; the API is only slightly different.
When you don’t know the length of the variable you query, you guessed wrong on the first attempt, and other threads are changing the environment in the background, you might need 3 of even more calls to either function (passing longer output buffers) to successfully retrieve the complete variable.
- deleted 3y ago[deleted]
- NekkoDroid 3y agoYou are right, I mixed up my functions. What I actually meant was _dupenv_s