Skip to content

Commit

Permalink
Update NuGet packages
Browse files Browse the repository at this point in the history
Add exception messages
  • Loading branch information
menees committed Aug 7, 2022
1 parent 7a274aa commit 175a26c
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion src/Directory.Build.props
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
<PackageReference Include="Menees.Analyzers" Version="3.0.4">
<PackageReference Include="Menees.Analyzers" Version="3.0.9">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
Expand Down
2 changes: 1 addition & 1 deletion src/DiskUsage/DiskUsage.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
</PropertyGroup>

<ItemGroup>
<PackageReference Include="Menees.Windows.Forms" Version="5.0.3" />
<PackageReference Include="Menees.Windows.Forms" Version="5.1.1" />
<PackageReference Include="TreemapControl" Version="1.0.2" />
</ItemGroup>

Expand Down
4 changes: 2 additions & 2 deletions src/DiskUsage/NativeMethods.cs
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ public static long GetCompressedFileSize(string fileName)
int error = Marshal.GetLastWin32Error();
if (error != NO_ERROR)
{
throw new Win32Exception(error);
throw new Win32Exception(error, $"Unable to get compressed file size for \"{fileName}\".");
}
}

Expand All @@ -52,7 +52,7 @@ public static uint GetDiskClusterSize(DirectoryInfo directory)
if (!GetDiskFreeSpace(rootPath, out uint sectorsPerCluster, out uint bytesPerSector, out _, out _))
{
int error = Marshal.GetLastWin32Error();
throw new Win32Exception(error);
throw new Win32Exception(error, $"Unable to get cluster size for \"{rootPath}\".");
}

uint result = bytesPerSector * sectorsPerCluster;
Expand Down

0 comments on commit 175a26c

Please sign in to comment.