What's wrong with this code?
The most obvious thing is that it does not follow Drupal's coding standards at all. It makes it very difficult to read.

hook_init() is it's own hook, it should not be used as an access callbacks. Access callbacks need to return either TRUE or FALSE.