mirror of
https://git.proxmox.com/git/libgit2
synced 2025-06-20 17:22:30 +00:00
config: Only dereference value on success
This commit is contained in:
parent
67dad09bdb
commit
505f37b41a
@ -400,7 +400,7 @@ static int get_string_at_file(const char **out, git_config_file *file, const cha
|
||||
*out = NULL;
|
||||
|
||||
res = file->get(file, name, &entry);
|
||||
if (res != GIT_ENOTFOUND)
|
||||
if (!res)
|
||||
*out = entry->value;
|
||||
|
||||
return res;
|
||||
|
Loading…
Reference in New Issue
Block a user