mirror of
https://github.com/reactos/reactos.git
synced 2024-12-28 01:55:19 +00:00
return the length of the string excluding the null-termination character on success in GetEnvironmentVariable(). Thanks to Hartmut.
svn path=/trunk/; revision=16536
This commit is contained in:
parent
9b991b83fd
commit
fcc95c66a8
1 changed files with 2 additions and 2 deletions
|
@ -91,7 +91,7 @@ GetEnvironmentVariableA (
|
|||
/* free unicode variable name string */
|
||||
RtlFreeUnicodeString (&VarNameU);
|
||||
|
||||
return (VarValueU.Length / sizeof(WCHAR) + 1);
|
||||
return (VarValueU.Length / sizeof(WCHAR));
|
||||
}
|
||||
|
||||
|
||||
|
@ -133,7 +133,7 @@ GetEnvironmentVariableW (
|
|||
}
|
||||
}
|
||||
|
||||
return (VarValue.Length / sizeof(WCHAR) + 1);
|
||||
return (VarValue.Length / sizeof(WCHAR));
|
||||
}
|
||||
|
||||
|
||||
|
|
Loading…
Reference in a new issue