]> source.dussan.org Git - tigervnc.git/commitdiff
Timely added check for unsupported pixel format.
authorgeorge82 <george82@3789f03b-4d11-0410-bbf8-ca57d06f2519>
Sat, 23 Sep 2006 07:17:20 +0000 (07:17 +0000)
committergeorge82 <george82@3789f03b-4d11-0410-bbf8-ca57d06f2519>
Sat, 23 Sep 2006 07:17:20 +0000 (07:17 +0000)
git-svn-id: svn://svn.code.sf.net/p/tigervnc/code/trunk@2104 3789f03b-4d11-0410-bbf8-ca57d06f2519

win/rfb_win32/ScaledDIBSectionBuffer.cxx

index 20d0f89a94aabec68a04c1ca1328f21c40204072..3b0f3f7e3c582c2566d9b5dbc8b65b2a737d5429 100644 (file)
@@ -51,7 +51,7 @@ void ScaledDIBSectionBuffer::setScaleRatio(double scale_ratio_) {
 void ScaledDIBSectionBuffer::setPF(const PixelFormat &pf_) {
   if (memcmp(&(ScaledPixelBuffer::pf), &pf_, sizeof(pf_)) == 0) return;
 
-  if (!pf_.trueColour) throw rfb::UnsupportedPixelFormatException();
+  if (pf_.depth != 24) throw rfb::UnsupportedPixelFormatException();
 
   pf = pf_;
   if (scaling) {