122 references to SizeOf
mscorlib (18)
microsoft\win32\registrykey.cs (1)
370secAttrs.nLength = (int)Marshal.SizeOf(secAttrs);
microsoft\win32\win32native.cs (2)
401OSVersionInfoSize = (int)Marshal.SizeOf(this); 418OSVersionInfoSize = (int)Marshal.SizeOf(this);
system\deployment\isolationinterop.cs (3)
1302IntPtr Reference = Marshal.AllocCoTaskMem(Marshal.SizeOf(this)); 2743IntPtr p = Marshal.AllocCoTaskMem(Marshal.SizeOf(this)); 2789IntPtr p = Marshal.AllocCoTaskMem(Marshal.SizeOf(this));
system\environment.cs (1)
1426if (Win32Native.GetUserObjectInformation(hwinsta, Win32Native.UOI_FLAGS, flags, Marshal.SizeOf(flags),ref lengthNeeded)) {
system\io\directory.cs (1)
309secAttrs.nLength = (int)Marshal.SizeOf(secAttrs);
system\io\filestream.cs (2)
1084secAttrs.nLength = (int)Marshal.SizeOf(secAttrs); 1101secAttrs.nLength = (int)Marshal.SizeOf(secAttrs);
system\io\longpath.cs (1)
543secAttrs.nLength = (int)Marshal.SizeOf(secAttrs);
system\runtime\interopservices\windowsruntime\clripropertyvalueimpl.cs (1)
525Buffer.Memcpy(pUnboxed, pData, Marshal.SizeOf(unboxed));
system\runtime\memoryfailpoint.cs (1)
371UIntPtr sizeOfMemInfo = (UIntPtr) Marshal.SizeOf(memInfo);
system\security\accesscontrol\privilege.cs (2)
524( uint )Marshal.SizeOf( previousState ), 641( uint )Marshal.SizeOf( previousState ),
system\security\principal\windowsidentity.cs (1)
1556offset += Marshal.SizeOf(windowsClaim);
system\threading\eventwaithandle.cs (1)
115secAttrs.nLength = (int)Marshal.SizeOf(secAttrs);
system\threading\mutex.cs (1)
74secAttrs.nLength = (int)Marshal.SizeOf(secAttrs);
PresentationFramework (1)
src\Framework\MS\Internal\Printing\PrintDlgExMarshaler.cs (1)
798return Marshal.SizeOf(temp) == 8;
SMSvcHost (1)
System\ServiceModel\Activation\ListenerAdapterBase.cs (1)
63listenerCallbacks.dwBytesInCallbackStructure = Marshal.SizeOf(listenerCallbacks);
System (38)
compmod\microsoft\win32\NativeMethods.cs (3)
129cb = Marshal.SizeOf(this); 243secAttrs.nLength = Marshal.SizeOf(secAttrs); 1468cbSize = Marshal.SizeOf(this);
compmod\microsoft\win32\SystemEvents.cs (1)
126if (UnsafeNativeMethods.GetUserObjectInformation(new HandleRef(null, hwinsta), NativeMethods.UOI_FLAGS, flags, Marshal.SizeOf(flags), ref lengthNeeded)) {
compmod\system\codedom\compiler\Executor.cs (1)
176si.cb = Marshal.SizeOf(si);
net\System\Net\_SafeNetHandles.cs (6)
938criteriaArray = AllocBuffer(criteriaCount * Marshal.SizeOf(criteria)); 946paraArray = AllocBuffer(Marshal.SizeOf(oidString)); 966IntPtr keyUsageCriteria = AllocBuffer(Marshal.SizeOf(CERT_DIGITAL_SIGNATURE_KEY_USAGE)); 970IntPtr pCertExtension = AllocBuffer(Marshal.SizeOf(certExtension)); 974paraArray = AllocBuffer(Marshal.SizeOf(pCertExtension)); 979Marshal.StructureToPtr(criteria, criteriaArray + Marshal.SizeOf(criteria), false);
net\System\Net\NetworkInformation\SystemIPGlobalProperties.cs (8)
176newPtr = (IntPtr)((long)newPtr + Marshal.SizeOf(tcpTableInfo.numberOfEntries)); 183newPtr = (IntPtr)((long)newPtr + Marshal.SizeOf(tcpRow)); 225newPtr = (IntPtr)((long)newPtr + Marshal.SizeOf(tcpTable6OwnerPid.numberOfEntries)); 234newPtr = (IntPtr)((long)newPtr + Marshal.SizeOf(tcp6RowOwnerPid)); 281newPtr = (IntPtr)((long)newPtr + Marshal.SizeOf(udpTableInfo.numberOfEntries)); 289newPtr = (IntPtr)((long)newPtr + Marshal.SizeOf(udpRow)); 328newPtr = (IntPtr)((long)newPtr + Marshal.SizeOf(udp6TableOwnerPid.numberOfEntries)); 339newPtr = (IntPtr)((long)newPtr + Marshal.SizeOf(udp6RowOwnerPid));
net\System\Net\Sockets\_AcceptOverlappedAsyncResult.cs (1)
87Marshal.SizeOf(handle));
net\System\Net\Sockets\Socket.cs (1)
9835Marshal.SizeOf(handle));
net\System\Net\UnsafeNativeMethods.cs (2)
330connectionStatus.dwSize = (uint)Marshal.SizeOf(connectionStatus); 3436info.cbSize = Marshal.SizeOf(info);
security\system\security\cryptography\x509\x509chain.cs (3)
279if (cbSize > Marshal.SizeOf(pChain)) 280cbSize = (uint) Marshal.SizeOf(pChain); 362ChainPara.cbSize = (uint) Marshal.SizeOf(ChainPara);
security\system\security\cryptography\x509\x509chainelement.cs (4)
28if (cbSize > Marshal.SizeOf(chainElement)) 29cbSize = (uint) Marshal.SizeOf(chainElement); 77if (cbSize > Marshal.SizeOf(simpleChain)) 78cbSize = (uint) Marshal.SizeOf(simpleChain);
services\monitoring\system\diagnosticts\EventLog.cs (1)
1043osv.dwOSVersionInfoSize = (uint)Marshal.SizeOf(osv);
services\monitoring\system\diagnosticts\ProcessManager.cs (5)
385thread.dwSize = Marshal.SizeOf(thread); 669if (!NativeMethods.GetModuleInformation(processHandle, new HandleRef(null, moduleHandle), ntModuleInfo, Marshal.SizeOf(ntModuleInfo))) 737int status = NativeMethods.NtQueryInformationProcess(processHandle, NativeMethods.NtQueryProcessBasicInfo, info, (int)Marshal.SizeOf(info), null); 1204currentPtr = (IntPtr)((long)currentPtr + Marshal.SizeOf(pi)); 1220currentPtr = (IntPtr)((long)currentPtr + Marshal.SizeOf(ti));
sys\system\io\ports\SerialStream.cs (1)
1271dcb.DCBlength = (uint) System.Runtime.InteropServices.Marshal.SizeOf(dcb);
sys\system\threading\semaphore.cs (1)
127secAttrs.nLength = (int)Marshal.SizeOf(secAttrs);
System.Core (9)
System\Diagnostics\Eventing\Reader\NativeWrapper.cs (2)
904pointer = new IntPtr(((Int64)pointer + Marshal.SizeOf(varVal))); 945pointer = new IntPtr(((Int64)pointer + Marshal.SizeOf(varVal)));
System\IO\LogStream.cs (1)
460secAttrs.nLength = (int)Marshal.SizeOf(secAttrs);
System\IO\MemoryMappedFiles\MemoryMappedFile.cs (1)
784secAttrs.nLength = (Int32)Marshal.SizeOf(secAttrs);
System\IO\MemoryMappedFiles\MemoryMappedView.cs (2)
124UnsafeNativeMethods.VirtualQuery(viewHandle, ref viewInfo, (IntPtr)Marshal.SizeOf(viewInfo)); 152UnsafeNativeMethods.VirtualQuery(viewHandle, ref viewInfo, (IntPtr)Marshal.SizeOf(viewInfo));
System\IO\Pipes\PipeStream.cs (2)
1187secAttrs.nLength = (int)Marshal.SizeOf(secAttrs); 1210secAttrs.nLength = (int)Marshal.SizeOf(secAttrs);
System\Security\Cryptography\CapiNative.cs (1)
743int* pSize = (int *)(pBlob + Marshal.SizeOf(*pHeader));
System.Data (2)
fx\src\data\System\Data\SQLTypes\SQLFileStream.cs (2)
895pbBuffer = Marshal.AllocHGlobal ( Marshal.SizeOf ( objectName ) ); 1053m_cbBuffer = Marshal.SizeOf(eaBuffer) + eaBuffer.EaNameLength + eaBuffer.EaValueLength;
System.Drawing (1)
commonui\System\Drawing\SystemFonts.cs (1)
259bool result = UnsafeNativeMethods.SystemParametersInfo(NativeMethods.SPI_GETICONTITLELOGFONT, Marshal.SizeOf(itfont), itfont, 0);
System.IO.Log (1)
System\IO\Log\LogStore.cs (1)
507secAttrs.nLength = (int)Marshal.SizeOf(secAttrs);
System.Runtime.Remoting (1)
channels\ipc\ipcport.cs (1)
74attr.nLength = (int)Marshal.SizeOf(attr);
System.Security (2)
system\security\cryptography\x509\x509ui.cs (1)
59ViewInfo.dwSize = (uint) Marshal.SizeOf(ViewInfo);
system\security\cryptography\x509\x509utils.cs (1)
312ChainPara.cbSize = (uint) Marshal.SizeOf(ChainPara);
System.ServiceModel (4)
System\ServiceModel\Channels\PeerUnsafeNativeMethods.cs (2)
240int size = Marshal.SizeOf(socketAddressList); 251int size = Marshal.SizeOf(socketAddressList);
System\ServiceModel\Channels\PnrpPeerResolver.cs (1)
1875pnrpInfo.dwSize = Marshal.SizeOf(pnrpInfo);
System\ServiceModel\ComIntegration\ComPlusAuthorization.cs (1)
322uint PrivilegeSetLength = (uint)Marshal.SizeOf(PrivilegeSet);
System.Web (5)
Configuration\RemoteWebConfigurationHost.cs (4)
513ciptr = Marshal.AllocCoTaskMem(Marshal.SizeOf(ci)); 517captr = Marshal.AllocCoTaskMem(Marshal.SizeOf(ca)); 573ciptr = Marshal.AllocCoTaskMem(Marshal.SizeOf(ci)); 577captr = Marshal.AllocCoTaskMem(Marshal.SizeOf(ca));
StaticFileHandler.cs (1)
402int byteCount = byteRanges.Length * Marshal.SizeOf(byteRanges[0]);
System.Windows.Forms (21)
parent\parent\parent\public\Internal\NDP\Inc\IsolationInterop.cs (4)
1317IntPtr Reference = Marshal.AllocCoTaskMem(Marshal.SizeOf(this)); 2759IntPtr p = Marshal.AllocCoTaskMem(Marshal.SizeOf(this)); 2782IntPtr p = Marshal.AllocCoTaskMem(Marshal.SizeOf(this)); 2805IntPtr p = Marshal.AllocCoTaskMem(Marshal.SizeOf(this));
winforms\Managed\System\WinForms\Control.cs (1)
19313if (UnsafeNativeMethods.GetObject(hBitmap, Marshal.SizeOf(bmp), bmp) == 0) {
winforms\Managed\System\WinForms\ControlPaint.cs (3)
153header.biSize = Marshal.SizeOf(header); 177IntPtr address = Marshal.AllocCoTaskMem(Marshal.SizeOf(header) + entryCount*4); 179Marshal.Copy(colors, 0, (IntPtr)((long)address + Marshal.SizeOf(header)), entryCount);
winforms\Managed\System\WinForms\DataGridToolTip.cs (3)
40icc.dwSize = Marshal.SizeOf(icc); 67toolInfo.cbSize = Marshal.SizeOf(toolInfo); 79toolInfo.cbSize = Marshal.SizeOf(toolInfo);
winforms\Managed\System\WinForms\ErrorProvider.cs (4)
918toolInfo.cbSize = Marshal.SizeOf(toolInfo); 960icc.dwSize = Marshal.SizeOf(icc); 1132toolInfo.cbSize = Marshal.SizeOf(toolInfo); 1222toolInfo.cbSize = Marshal.SizeOf(toolInfo);
winforms\Managed\System\WinForms\ImageList.cs (1)
321UnsafeNativeMethods.GetObject(new HandleRef(null, imageInfo.hbmImage), Marshal.SizeOf(bmp), bmp);
winforms\Managed\System\WinForms\Printing\PageSetupDialog.cs (1)
360data.lStructSize = Marshal.SizeOf(data);
winforms\Managed\System\WinForms\Printing\PrintDialog.cs (2)
295data.lStructSize = Marshal.SizeOf(data); 322data.lStructSize = Marshal.SizeOf(data);
winforms\Managed\System\WinForms\SystemInformation.cs (2)
86data.cbSize = Marshal.SizeOf(data); 1135if (UnsafeNativeMethods.GetUserObjectInformation(new HandleRef(null, hwinsta), NativeMethods.UOI_FLAGS, flags, Marshal.SizeOf(flags), ref lengthNeeded)) {
System.Workflow.ComponentModel (1)
AuthoringOM\Design\DesignerWidgets.cs (1)
2392toolInfo.size = Marshal.SizeOf(toolInfo);
UIAutomationClient (3)
MS\Internal\Automation\Input.cs (2)
73Misc.SendInput(1, ref ki, Marshal.SizeOf(ki)); 90Misc.SendInput(1, ref ki, Marshal.SizeOf(ki));
MS\Internal\Automation\Misc.cs (1)
360guiThreadInfo.cbSize = Marshal.SizeOf(guiThreadInfo);
UIAutomationClientsideProviders (4)
MS\Internal\AutomationProxies\CommonXSendMessage.cs (1)
163if (Marshal.SizeOf(hwnd) == sizeof(int))
MS\Internal\AutomationProxies\Input.cs (3)
127if( UnsafeNativeMethods.SendInput( 1, ref mi, Marshal.SizeOf(mi) ) == 0 ) 150if( UnsafeNativeMethods.SendInput( 1, ref ki, Marshal.SizeOf(ki) ) == 0 ) 173Misc.SendInput(1, ref ki, Marshal.SizeOf(ki));
WsatConfig (4)
Configuration\WsatServiceAddress.cs (2)
58int configInformationLength = Marshal.SizeOf(configInformation); 121int configInformationSize = Marshal.SizeOf(configInformation);
Configuration\WsatServiceCertificate.cs (2)
66int configInformationLength = Marshal.SizeOf(sslConf); 143int configInformationLength = System.Runtime.InteropServices.Marshal.SizeOf(sslConf);
WsatUI (6)
Configuration\ETWSafeNativeMethods.cs (2)
138Head.Wnode.BufferSize = (uint)(Marshal.SizeOf(this)); 139Head.LogFileNameOffset = (uint)(Marshal.SizeOf(this) - Tail.LogFileName.Length * sizeof(char));
Configuration\WsatServiceAddress.cs (2)
58int configInformationLength = Marshal.SizeOf(configInformation); 121int configInformationSize = Marshal.SizeOf(configInformation);
Configuration\WsatServiceCertificate.cs (2)
66int configInformationLength = Marshal.SizeOf(sslConf); 143int configInformationLength = System.Runtime.InteropServices.Marshal.SizeOf(sslConf);