There is a semicolon after the if's condition:
if (inGroc == NULL);
Remove it to fix your problem.
The semicolon there says, when the condition of your if statement is true, do nothing.
Make sure you do not have "random" semicolons in your code.