Skip to content

Commit

Permalink
Ensure GError is initialized to NULL in hunspell provider (fix #356)
Browse files Browse the repository at this point in the history
  • Loading branch information
rrthomas committed Feb 8, 2024
1 parent ea28e1a commit 99ca772
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion providers/enchant_hunspell.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -295,7 +295,7 @@ hunspell_request_dictionary (const char * tag)
s_buildDictionaryDirs (dirs);

for (size_t i = 0; i < dirs.size(); i++) {
GError *err;
GError *err = NULL;
GDir *dir = g_dir_open (dirs[i].c_str(), 0, &err);
g_assert ((dir == NULL && err != NULL) || (dir != NULL && err == NULL));
if (err == NULL) {
Expand Down

0 comments on commit 99ca772

Please sign in to comment.