grendizerufo / nvidia-texture-tools

Automatically exported from code.google.com/p/nvidia-texture-tools
Other
0 stars 0 forks source link

Missing bracket in PNG code of ImageIO.cpp #173

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
There is a bracket missing in line 799 in ImageIO.cpp 

It should be
memset(text, 0, count * sizeof(png_text));
instead of 
memset(text, 0, count * sizeof(png_text);

Due to a const-char* to char* conversion further down, the code won't compile. 
But it compiles and executes just fine, after applying this hack:
            text[i].key = (char*)(void*)tags[2 * i + 0];
            text[i].text = (char*)(void*)tags[2 * i + 1];

Original issue reported on code.google.com by eod...@gmail.com on 10 Apr 2012 at 12:36