Skip to content
This repository was archived by the owner on Dec 15, 2022. It is now read-only.

Commit 14d4371

Browse files
committed
guard null to match remainder of calls in file
1 parent 1248408 commit 14d4371

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

src/keytar_win.cc

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -228,6 +228,9 @@ KEYTAR_OP_RESULT FindCredentials(const std::string& service,
228228
std::vector<Credentials>* credentials,
229229
std::string* errStr) {
230230
LPWSTR filter = utf8ToWideChar(service + "*");
231+
if (filter == NULL) {
232+
return FAIL_ERROR;
233+
}
231234

232235
DWORD count;
233236
CREDENTIAL **creds;

0 commit comments

Comments
 (0)