fixed a few bugs - orphaned client tcp ports, sql error (Matt fixed in v1.63 which we are merging in this commit)