Fixed old shared value race condition, and caught errors in sendClient