VirtualBox

Changeset 35759 in vbox for trunk/src/VBox


Ignore:
Timestamp:
Jan 28, 2011 1:06:58 PM (14 years ago)
Author:
vboxsync
Message:

DevVGA: verify the size of the screenshot.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Devices/Graphics/DevVGA.cpp

    r35409 r35759  
    46054605    size_t cbRequired = pThis->last_scr_width * 4 * pThis->last_scr_height;
    46064606
    4607     if (cbRequired)
     4607    /* The size can't be zero or greater than the size of the VRAM.
     4608     * Inconsistent VGA device state can cause the incorrect size values.
     4609     */
     4610    if (cbRequired && cbRequired <= pThis->vram_size)
    46084611    {
    46094612        uint8_t *pu8Data = (uint8_t *)RTMemAlloc(cbRequired);
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette