Get rid of needless allocation in read_tga