SocketClient: Merged updates from jb-mr1.1-release branch of aosp