Fixed ctpyes view errors

bug in odd number of elements and ctype buffers fixed.