try-finally for the lock in inet Connection