fixed reconnecting when sync server got disconnected.