VirtualBox

Changeset 10561 in vbox for trunk/src/VBox


Ignore:
Timestamp:
Jul 12, 2008 1:15:45 AM (16 years ago)
Author:
vboxsync
Message:

Get the size right.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Additions/x11/xmouse/VBoxUtils_68.c

    r10555 r10561  
    122122    req.pointerXPos = 0;
    123123    req.pointerYPos = 0;
    124     if (ioctl(g_vboxaddHandle, VBOXGUEST_IOCTL_VMMREQUEST(0), (void*)&req) < 0)
     124    if (ioctl(g_vboxaddHandle, VBOXGUEST_IOCTL_VMMREQUEST(sizeof(req)), (void*)&req) < 0)
    125125    {
    126126        ErrorF("Error sending mouse pointer capabilities to VMM! rc = %d (%s)\n",
     
    146146        return 1;
    147147    /* perform VMM request */
    148     if (ioctl(g_vboxaddHandle, VBOXGUEST_IOCTL_VMMREQUEST(0), (void*)g_vmmreqMouseStatus) >= 0)
     148    if (ioctl(g_vboxaddHandle, VBOXGUEST_IOCTL_VMMREQUEST(vmmdevGetRequestSize(VMMDevReq_GetMouseStatus)), (void*)g_vmmreqMouseStatus) >= 0)
    149149    {
    150150        if (VBOX_SUCCESS(g_vmmreqMouseStatus->header.rc))
     
    157157                return 0;
    158158            }
    159             else
    160                 return 1;
     159            return 1;
    161160        }
    162         else
    163         {
    164             ErrorF("Error querying host mouse position! header.rc = %d\n", g_vmmreqMouseStatus->header.rc);
    165         }
     161        ErrorF("Error querying host mouse position! header.rc = %d\n", g_vmmreqMouseStatus->header.rc);
    166162    }
    167163    else
     
    185181    req.pointerXPos = 0;
    186182    req.pointerYPos = 0;
    187     if (ioctl(g_vboxaddHandle, VBOXGUEST_IOCTL_VMMREQUEST(0), (void*)&req) < 0)
     183    if (ioctl(g_vboxaddHandle, VBOXGUEST_IOCTL_VMMREQUEST(sizeof(req)), (void*)&req) < 0)
    188184    {
    189185        ErrorF("ioctl to vboxadd module failed, rc = %d (%s)\n",
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