I would give this a more meaningful name since it is tested as well as returned within the function.  E.g.,

bool valid;

then your test at the bottom would read

if (!valid)

which would be more understandable.