Skip to content

Commit e0b67a2

Browse files
authored
[MSVIDC32] Keep using CRAM_MAGIC for info structure validation (reactos#6498)
CRAM_MAGIC is being used to validate the info context structure contents when the driver routines are being called, so partially revert 8be9121. Just report "MSVC" as the main FourCC handler in CRAM_GetInfo() instead. CORE-19453 CORE-15382
1 parent fa29a61 commit e0b67a2

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

dll/win32/msvidc32/msvideo1.c

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -538,7 +538,11 @@ static LRESULT CRAM_GetInfo( const Msvideo1Context *info, ICINFO *icinfo, DWORD
538538

539539
icinfo->dwSize = sizeof(ICINFO);
540540
icinfo->fccType = ICTYPE_VIDEO;
541+
#ifdef __REACTOS__
542+
icinfo->fccHandler = MSVC_MAGIC;
543+
#else
541544
icinfo->fccHandler = info ? info->dwMagic : CRAM_MAGIC;
545+
#endif
542546
icinfo->dwFlags = 0;
543547
icinfo->dwVersion = ICVERSION;
544548
icinfo->dwVersionICM = ICVERSION;
@@ -583,11 +587,7 @@ LRESULT WINAPI CRAM_DriverProc( DWORD_PTR dwDriverId, HDRVR hdrvr, UINT msg,
583587
if( info )
584588
{
585589
memset( info, 0, sizeof *info );
586-
#ifdef __REACTOS__
587-
info->dwMagic = MSVC_MAGIC;
588-
#else
589590
info->dwMagic = CRAM_MAGIC;
590-
#endif
591591
}
592592
r = (LRESULT) info;
593593
break;

0 commit comments

Comments
 (0)