mirror of
https://git.pwmt.org/pwmt/zathura.git
synced 2025-01-30 17:34:55 +01:00
Error handling
This commit is contained in:
parent
7f38470a9e
commit
ff976d4854
1 changed files with 6 additions and 1 deletions
|
@ -672,7 +672,12 @@ zathura_db_read_key_file_from_file(const char* path)
|
|||
|
||||
free(content);
|
||||
content = malloc(sizeof(char) * (dummy_len + 1));
|
||||
content = memcpy(content, dummy_content, dummy_len + 1);
|
||||
if (content == NULL)
|
||||
{
|
||||
g_key_file_free(key_file);
|
||||
return NULL;
|
||||
}
|
||||
g_strlcat(content, dummy_content, dummy_len + 1);
|
||||
contentlen = dummy_len;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue