Unfortunately the library can get stuck in the "closing" state if anything at all goes wrong during the save step, or any background tasks terminates unexpectedly.
Does it get stuck in this state even if you simply open your Library and quit immediately? If not, what actions are required to make it get stuck? (Scanning, editing data, etc.)
Also, there may be pertinent information printed to the console. Open Console.app, and filter by "neat". There may be an exception or error displayed that would help us isolated the problem.