Fix socket adapter write mode