Fixed out-of-bounds exception on 'ret' statements.