VirtualBox

Ignore:
Timestamp:
Apr 19, 2020 2:02:30 AM (5 years ago)
Author:
vboxsync
Message:

Add/NT/Graphics: VC++ 14.1 warnings. bugref:8489

Location:
trunk/src/VBox/Additions/WINNT/Graphics/Video/mp
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Additions/WINNT/Graphics/Video/mp/common/VBoxMPVidModes.cpp

    r82968 r83827  
    1818#include "VBoxMPCommon.h"
    1919
    20 #if _MSC_VER >= 1400 /* bird: MS fixed swprintf to be standard-conforming... */
     20#if _MSC_VER >= 1400 && _MSC_VER <= 1410 /* bird: MS fixed swprintf to be standard-conforming... */
    2121#define _INC_SWPRINTF_INL_
    2222extern "C" int __cdecl swprintf(wchar_t *, const wchar_t *, ...);
     
    802802         * regardless of conditions always add 2 entries to the table.
    803803         */
    804         BOOLEAN bAlternativeIndex = FALSE;
     804        bAlternativeIndex = FALSE;
    805805
    806806        BOOLEAN bChanged = (pExt->Prev_xres!=specialMode.VisScreenWidth
  • trunk/src/VBox/Additions/WINNT/Graphics/Video/mp/wddm/VBoxMPMisc.cpp

    r82968 r83827  
    10911091static void vboxUmdDumpDword(DWORD *pvData, DWORD cData)
    10921092{
    1093     char aBuf[16*4];
    10941093    DWORD dw1, dw2, dw3, dw4;
    10951094    for (UINT i = 0; i < (cData & (~3)); i+=4)
     
    10991098        dw3 = *pvData++;
    11001099        dw4 = *pvData++;
    1101         sprintf(aBuf, "0x%08x, 0x%08x, 0x%08x, 0x%08x,\n", dw1, dw2, dw3, dw4);
    1102         LOGREL(("%s", aBuf));
     1100        LOGREL(("0x%08x, 0x%08x, 0x%08x, 0x%08x,\n", dw1, dw2, dw3, dw4));
    11031101    }
    11041102
     
    11101108            dw2 = *pvData++;
    11111109            dw3 = *pvData++;
    1112             sprintf(aBuf, "0x%08x, 0x%08x, 0x%08x\n", dw1, dw2, dw3);
    1113             LOGREL(("%s", aBuf));
     1110            LOGREL(("0x%08x, 0x%08x, 0x%08x\n", dw1, dw2, dw3));
    11141111            break;
    11151112        case 2:
    11161113            dw1 = *pvData++;
    11171114            dw2 = *pvData++;
    1118             sprintf(aBuf, "0x%08x, 0x%08x\n", dw1, dw2);
    1119             LOGREL(("%s", aBuf));
     1115            LOGREL(("0x%08x, 0x%08x\n", dw1, dw2));
    11201116            break;
    11211117        case 1:
    11221118            dw1 = *pvData++;
    1123             sprintf(aBuf, "0x%8x\n", dw1);
    1124             LOGREL(("%s", aBuf));
     1119            LOGREL(("0x%8x\n", dw1));
    11251120            break;
    11261121        default:
  • trunk/src/VBox/Additions/WINNT/Graphics/Video/mp/wddm/VBoxMPWddm.cpp

    r82968 r83827  
    33163316                if (pAlloc->bAssigned)
    33173317                {
    3318                     PVBOXMP_DEVEXT pDevExt = pDevice->pAdapter;
    3319                     Assert(pAlloc->AllocData.SurfDesc.VidPnSourceId < (D3DDDI_VIDEO_PRESENT_SOURCE_ID)VBoxCommonFromDeviceExt(pDevExt)->cDisplays);
    3320                     PVBOXWDDM_SOURCE pSource = &pDevExt->aSources[pAlloc->AllocData.SurfDesc.VidPnSourceId];
     3318                    PVBOXMP_DEVEXT pDevExt2 = pDevice->pAdapter;
     3319                    Assert(pAlloc->AllocData.SurfDesc.VidPnSourceId < (D3DDDI_VIDEO_PRESENT_SOURCE_ID)VBoxCommonFromDeviceExt(pDevExt2)->cDisplays);
     3320                    PVBOXWDDM_SOURCE pSource = &pDevExt2->aSources[pAlloc->AllocData.SurfDesc.VidPnSourceId];
    33213321                    if (pSource->AllocData.hostID != pAlloc->AllocData.hostID)
    33223322                    {
     
    33243324                        pSource->u8SyncState &= ~VBOXWDDM_HGSYNC_F_SYNCED_LOCATION;
    33253325
    3326                         vboxWddmGhDisplayCheckSetInfo(pDevExt);
     3326                        vboxWddmGhDisplayCheckSetInfo(pDevExt2);
    33273327                    }
    33283328                }
  • trunk/src/VBox/Additions/WINNT/Graphics/Video/mp/wddm/gallium/VBoxMPGaWddm.cpp

    r83694 r83827  
    14761476    gaFenceObjectsLock(pGaDevExt);
    14771477
    1478     GAFENCEOBJECT *pIter, *pNext;
    1479     RTListForEachSafe(&pGaDevExt->fenceObjects.list, pIter, pNext, GAFENCEOBJECT, node)
    1480     {
    1481         if (pIter->u32FenceState == GAFENCE_STATE_SUBMITTED)
    1482         {
    1483             if (gaFenceCmp(pIter->u32SubmissionFenceId, u32LastCompletedFenceId) <= 0)
    1484             {
    1485                 GALOG(("u32SubmissionFenceId %u -> SIGNALED %RU64 ns\n",
    1486                        pIter->u32SubmissionFenceId, RTTimeNanoTS() - pIter->u64SubmittedTS));
    1487 
    1488                 ASMAtomicWriteU32(&pGaDevExt->u32LastCompletedSeqNo, pIter->u32SeqNo);
    1489                 pIter->u32FenceState = GAFENCE_STATE_SIGNALED;
    1490                 if (RT_BOOL(pIter->fu32FenceFlags & GAFENCE_F_WAITED))
     1478    {
     1479        GAFENCEOBJECT *pIter, *pNext;
     1480        RTListForEachSafe(&pGaDevExt->fenceObjects.list, pIter, pNext, GAFENCEOBJECT, node)
     1481        {
     1482            if (pIter->u32FenceState == GAFENCE_STATE_SUBMITTED)
     1483            {
     1484                if (gaFenceCmp(pIter->u32SubmissionFenceId, u32LastCompletedFenceId) <= 0)
    14911485                {
    1492                     KeSetEvent(&pIter->event, 0, FALSE);
     1486                    GALOG(("u32SubmissionFenceId %u -> SIGNALED %RU64 ns\n",
     1487                           pIter->u32SubmissionFenceId, RTTimeNanoTS() - pIter->u64SubmittedTS));
     1488
     1489                    ASMAtomicWriteU32(&pGaDevExt->u32LastCompletedSeqNo, pIter->u32SeqNo);
     1490                    pIter->u32FenceState = GAFENCE_STATE_SIGNALED;
     1491                    if (RT_BOOL(pIter->fu32FenceFlags & GAFENCE_F_WAITED))
     1492                    {
     1493                        KeSetEvent(&pIter->event, 0, FALSE);
     1494                    }
     1495
     1496                    GaFenceUnrefLocked(pGaDevExt, pIter);
    14931497                }
    1494 
    1495                 GaFenceUnrefLocked(pGaDevExt, pIter);
    14961498            }
    14971499        }
  • trunk/src/VBox/Additions/WINNT/Graphics/Video/mp/xpdm/VBoxMPIOCTL.cpp

    r82968 r83827  
    3434    }
    3535
     36#ifndef DOXYGEN_RUNNING
     37# if RT_MSC_PREREQ(RT_MSC_VER_VC141)
     38/* VBoxMPIOCTL.cpp(80): warning C4457: declaration of 'pRequestedAddress' hides function parameter (caused by VBOXMPIOCTL_HIDE) */
     39#  pragma warning(disable:4457 )
     40# endif
     41#endif
     42
    3643/* Called for IOCTL_VIDEO_RESET_DEVICE.
    3744 * Reset device to a state it comes at system boot time.
     
    8895        pMapInfo->FrameBufferBase = (PUCHAR)pMapInfo->VideoRamBase;
    8996        pMapInfo->FrameBufferLength =
    90             VBoxMPXpdmCurrentVideoMode(pExt)->VisScreenHeight*
     97            VBoxMPXpdmCurrentVideoMode(pExt)->VisScreenHeight *
    9198            VBoxMPXpdmCurrentVideoMode(pExt)->ScreenStride;
    9299
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