Skip to content

Commit

Permalink
file_systems/QueryParser.h: Fix -Werror=maybe-uninitialized
Browse files Browse the repository at this point in the history
Fix fPosition and fTerm not being initialized when expr is NULL
at line 1162.
Pointed out by GCC14.

Change-Id: If883ac0cc32e3418d0e3b49b42012efd861d65f4
Reviewed-on: https://review.haiku-os.org/c/haiku/+/7641
Haiku-Format: Haiku-format Bot <no-reply+haikuformatbot@haiku-os.org>
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
Reviewed-by: Jérôme Duval <jerome.duval@gmail.com>
  • Loading branch information
mt819 authored and waddlesplash committed May 8, 2024
1 parent 0ec6e1c commit ddbb992
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions headers/private/file_systems/QueryParser.h
Expand Up @@ -1158,6 +1158,9 @@ Equation<QueryPolicy>::PrintToStream()

template<typename QueryPolicy>
Expression<QueryPolicy>::Expression(char* expr)
:
fPosition(NULL),
fTerm(NULL)
{
if (expr == NULL)
return;
Expand Down

0 comments on commit ddbb992

Please sign in to comment.