Unified socket bug fix