Fix encoding for SmartOS