fix output errors: Cuba 3.2 interface is different from 4.1