Fix the problem that the service account cannot obtain current information

This commit is contained in:
s3cst4rs 2023-08-12 10:51:48 +08:00
parent 610d47a584
commit 12cafc07ac
1 changed files with 3 additions and 0 deletions

View File

@ -368,6 +368,9 @@ func (t Token) GetUserProfileDirectory() (string, error) {
if e == nil {
return UTF16ToString(b), nil
}
if e == ERROR_FILE_NOT_FOUND {
return "", nil
}
if e != ERROR_INSUFFICIENT_BUFFER {
return "", e
}