Clean sockets from encoders