Fix most pointer & datatype logic issues.  Some still remain