Skip to content

Commit

Permalink
fix: avoid inserting a nil into the gpu data dictionary literal (gets…
Browse files Browse the repository at this point in the history
  • Loading branch information
armcknight authored Jun 14, 2023
1 parent 253bb71 commit 3eb2a52
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
- Duplicated HTTP breadcrumbs (#3058)
- Expose SentryPrivate and SentrySwiftUI schemes for cartahge clients that have `--no-use-binaries` option (#3071)
- Convert last remaining `sprintf` call to `snprintf` (#3077)
- Fix a crash when serializing profiling data (#3092)

## 8.7.4

Expand Down
2 changes: 1 addition & 1 deletion Sources/Sentry/SentryProfiler.mm
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,7 @@
@"value" : obj[@"value"],
}];
}];
if (useMostRecentRecording && slicedGPUEntries.count == 0) {
if (useMostRecentRecording && slicedGPUEntries.count == 0 && nearestPredecessorValue != nil) {
[slicedGPUEntries addObject:@ {
@"elapsed_since_start_ns" : @"0",
@"value" : nearestPredecessorValue,
Expand Down

0 comments on commit 3eb2a52

Please sign in to comment.