TWIN: Fix various warnings