[krbdev.mit.edu #2636] replace all calls to getenv()/setenv() with Get/SetEnvironmentVariable on Windows

Jeffrey Altman jaltman at columbia.edu
Wed Jul 14 15:57:11 EDT 2004


Ken Raeburn wrote:

> Can this be done with a macro in win-mac.h?

Unfortunately not.  GetEnvironmentVariable() requires that the user
provide the input buffer as well as a length.  The return value is the
length of the returned string.

The variable is undefined if (GetLastError() == ERROR_ENVVAR_NOT_FOUND)


-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/x-pkcs7-signature
Size: 3256 bytes
Desc: S/MIME Cryptographic Signature
Url : http://mailman.mit.edu/pipermail/krb5-bugs/attachments/20040714/c360df6f/attachment.bin


More information about the krb5-bugs mailing list