X-Git-Url: http://git.tdb.fi/?p=libs%2Fgl.git;a=blobdiff_plain;f=source%2Ftexturecube.cpp;h=b9a8f5dd02b8cacb73f63df7bce028a5920035cd;hp=db679cf9e1259cb4feb0e087c0f3e066c40921c3;hb=3c46227c280bc4cd8a4487c648f2f080d5b4f7ea;hpb=7c4ccb88417c23f53e0c24c4cb025b9d35b1da76 diff --git a/source/texturecube.cpp b/source/texturecube.cpp index db679cf9..b9a8f5dd 100644 --- a/source/texturecube.cpp +++ b/source/texturecube.cpp @@ -64,6 +64,8 @@ void TextureCube::storage(PixelFormat fmt, unsigned sz) void TextureCube::allocate(unsigned level) { + if(size==0) + throw invalid_operation("TextureCube::allocate"); if(allocated&(1<