Skip to content

Commit

Permalink
Fix UWP GateKeeper errors (#2415)
Browse files Browse the repository at this point in the history
  • Loading branch information
mattjohnsonpint committed Jun 8, 2023
1 parent e01334e commit af9cc59
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 20 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
- Fix system frames being marked as "in-app" ([#2408](https://github.com/getsentry/sentry-dotnet/pull/2408))
- NOTE: This important fix corrects a value that is used during issue grouping, so you may receive new alerts for existing issues after deploying this update.
- Populate scope's Cookies property ([#2411](https://github.com/getsentry/sentry-dotnet/pull/2411))
- Fix UWP GateKeeper errors ([#2415](https://github.com/getsentry/sentry-dotnet/pull/2415))

### Dependencies

Expand Down
13 changes: 1 addition & 12 deletions src/Sentry/Internal/FastSerialization/GrowableArray.cs
Original file line number Diff line number Diff line change
Expand Up @@ -10,11 +10,6 @@ internal struct HashableGrowableArray<T> : IReadOnlyList<T>, IEquatable<Hashable
private int _hashCode = 0;
private bool _sealed = false;

public HashableGrowableArray()
{
_items = new GrowableArray<T>();
}

public HashableGrowableArray(int capacity)
{
_items = new GrowableArray<T>(capacity);
Expand Down Expand Up @@ -95,13 +90,7 @@ public bool Equals(HashableGrowableArray<T> other)
internal struct GrowableArray<T> : IReadOnlyList<T>
{
/// <summary>
/// Create an empty growable array.
/// </summary>
public GrowableArray() : this(0) { }

/// <summary>
/// Create a growable array with the given initial size it will grow as needed. There is also the
/// default constructor that assumes initialSize of 0 (and does not actually allocate the array.
/// Create a growable array with the given initial size it will grow as needed.
/// </summary>
/// <param name="initialSize"></param>
public GrowableArray(int initialSize)
Expand Down
8 changes: 1 addition & 7 deletions src/Sentry/Internal/SparseArray.cs
Original file line number Diff line number Diff line change
Expand Up @@ -9,13 +9,7 @@ internal sealed class SparseScalarArray<T> where T : IEquatable<T>
private GrowableArray<T> _items;
private T _uninitializedValue;

public SparseScalarArray(T uninitializedValue)
{
_items = new GrowableArray<T>();
_uninitializedValue = uninitializedValue;
}

public SparseScalarArray(T uninitializedValue, int capacity)
public SparseScalarArray(T uninitializedValue, int capacity = 0)
{
_items = new GrowableArray<T>(capacity);
_uninitializedValue = uninitializedValue;
Expand Down
2 changes: 1 addition & 1 deletion test/Sentry.Tests/Protocol/ProfilerTests.verify.cs
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ public ProfilerTests(ITestOutputHelper output)

private static void AddStack(SampleProfile sut, List<int> frames)
{
var stack = new HashableGrowableArray<int>();
var stack = new HashableGrowableArray<int>(0);
foreach (var frame in frames)
{
stack.Add(frame);
Expand Down

0 comments on commit af9cc59

Please sign in to comment.