mirror of
https://github.com/gnif/LookingGlass.git
synced 2026-08-25 16:32:37 +00:00
[common] rects: validate copy geometry
This commit is contained in:
@@ -1551,13 +1551,19 @@ static CaptureResult dxgi_getFrame(
|
||||
scaledDamageRects[i] = rect;
|
||||
}
|
||||
|
||||
rectsBufferToFramebuffer(scaledDamageRects, damage->count, this->bpp, frame,
|
||||
this->pitch, this->dataHeight, tex->map, this->pitch);
|
||||
if (!rectsBufferToFramebuffer(scaledDamageRects, damage->count,
|
||||
this->bpp, frame, this->pitch, this->dataHeight,
|
||||
tex->map, this->pitch))
|
||||
framebuffer_write(frame, tex->map,
|
||||
this->pitch * this->dataHeight);
|
||||
}
|
||||
else
|
||||
{
|
||||
rectsBufferToFramebuffer(damage->rects, damage->count, this->bpp, frame,
|
||||
this->pitch, this->dataHeight, tex->map, this->pitch);
|
||||
if (!rectsBufferToFramebuffer(damage->rects, damage->count,
|
||||
this->bpp, frame, this->pitch, this->dataHeight,
|
||||
tex->map, this->pitch))
|
||||
framebuffer_write(frame, tex->map,
|
||||
this->pitch * this->dataHeight);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user