Bump Microsoft.Windows.CsWin32 from 0.3.235 to 0.3.236 (#1999)
* Bump Microsoft.Windows.CsWin32 from 0.3.235 to 0.3.236 --- updated-dependencies: - dependency-name: Microsoft.Windows.CsWin32 dependency-version: 0.3.236 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <support@github.com> * Fix build compatibility with Microsoft.Windows.CsWin32 0.3.236 (#2000) * Initial plan * Fix compatibility with CsWin32 0.3.236 and resource path case sensitivity Co-authored-by: PhyxionNL <7643972+PhyxionNL@users.noreply.github.com> * Remove unnecessary local variable pData in BatteryGroup.cs Co-authored-by: PhyxionNL <7643972+PhyxionNL@users.noreply.github.com> --------- Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: PhyxionNL <7643972+PhyxionNL@users.noreply.github.com> --------- Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Copilot <198982749+Copilot@users.noreply.github.com> Co-authored-by: PhyxionNL <7643972+PhyxionNL@users.noreply.github.com>
This commit is contained in:
co-authored by
PhyxionNL
copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Copilot
parent
b1b76c3d18
commit
cbd3f4b1d2
@@ -10,6 +10,7 @@ using System.Globalization;
|
||||
using System.IO;
|
||||
using System.Text;
|
||||
using Windows.Win32;
|
||||
using Windows.Win32.Foundation;
|
||||
using Windows.Win32.Storage.FileSystem;
|
||||
using Windows.Win32.System.Ioctl;
|
||||
using LibreHardwareMonitor.Interop;
|
||||
@@ -184,7 +185,7 @@ public abstract class AbstractStorage : Hardware
|
||||
DISK_PERFORMANCE diskPerformance = new();
|
||||
|
||||
uint bytesReturned;
|
||||
if (!PInvoke.DeviceIoControl(_storageInfo.Handle, PInvoke.IOCTL_DISK_PERFORMANCE, null, 0, &diskPerformance, (uint)sizeof(DISK_PERFORMANCE), &bytesReturned, null))
|
||||
if (!PInvoke.DeviceIoControl((HANDLE)_storageInfo.Handle.DangerousGetHandle(), PInvoke.IOCTL_DISK_PERFORMANCE, null, 0, &diskPerformance, (uint)sizeof(DISK_PERFORMANCE), &bytesReturned, null))
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user