I tried that with MQ 4.4 (latest promoted build), using a connection factory created using the MQ admin tool. I removed the call to System.exit().
The client connected to the broker and then terminated.
I didn't have 4.3 immediately to hand, so I tried it with MQ 4.0. It worked using that as well.
When it "hangs" for you, can you perform a thread dump so I can see what threads are not being shut down properly?
Nigel
[Message sent by forum member 'nigeldeakin' (nigeldeakin)]
http://forums.java.net/jive/thread.jspa?messageID=361363