My version of gcc doesn't warn about this error (declaration in the middle of a set of statements). The fix is simple (this also corrects return code; for init functions it should be zero or error).