Bizarre Java error/bug: Stack Overflows, null pointers and double locking
===

I really don't know how to explain this error properly...

It started when I added this method to my controller class:

	public void loadPlayerComboBox() {
		try{
			final PreparedStatement collectPlayerNames = 
					ConnectionManager.getConnection().prepareStatement("SELECT "+PLAYER_NAME+"  FROM PLAYERS");
			final ResultSet playerNameResults = collectPlayerNames.executeQuery();
			while(playerNameResults.next()){
				IViewManager.Util.getInstance().getMyContainerPane().getMyPlayerManagerPane().getPlayerNameList()
				.add(playerNameResults.getString(PLAYER_NAME));
			}
		}catch(final SQLException e){
			System.out.println("SQLException. Reason: " + e.getMessage());
		}
	}

And I've confirmed that without this method (which is called on by a class, on start up of the program) I don't have an error.

My error? When I run from eclipse, the programe starts to load the top bar of the frame appears, but the actual content doesn't.

![enter image description here][1]

As well as this there is a strange drowing empty box, that I believe is caused by multiple processes being started up.

This, I beleive was caused by a stack overflow, as my getInstance() methods recursively called each other. I can't get the stacktrace back for some reason, and at the moment the debug screen is just blank. I've checked my .log and it doesn't have an error corresponding to that time stamp. I don't know how they could call each other though. Here is the ViewManager method:

    static class Util {
        static private IViewManager viewManager = null;
        static public synchronized IViewManager getInstance() {
                if (viewManager == null) {
                        viewManager = new ViewManager();
                }
                return viewManager;
        }
    }

The IController method is identical, except the names of the class and objects it calls are different. Double checked locking just causes the first instance of IViewManager.getInstance() in my launcher to return a null pointer, this is at the start of the synchronised block.

What would cause this sort of error? How can I even start to fix it?

  [1]: http://i.stack.imgur.com/9Pl8P.png