#619: Check for empty buffer. Fixes crash with some PNG images. (Lukasz Krzyzak)

This commit is contained in:
Andreas Huggel 2009-03-12 09:15:09 +00:00
parent 2b7a80d4bb
commit f827d8a380

View File

@ -619,6 +619,9 @@ namespace Exiv2 {
0,0,0,0,0,0,0,0,0,0, 0,0,0,0,0,0,0,0,0,0,
0,0,0,0,0,0,0,0,0,0, 0,0,0,0,0,0,0,10,11,12,
13,14,15};
if (text.size_ == 0) {
return DataBuf();
}
sp = (char*)text.pData_+1;