Skip to content

Commit 258bd46

Browse files
authored
CRITICAL: Fix double dispose on LazyLoadBitmap (#844)
# Main Goal Tryfix for launcher crash due to ODE during game/region switch. This is caused by the `using` clause on the stream causing the resultStream to somehow getting double disposed during the event `ImageOnImageOpened` and crashes about 95% of the time during game/region change. ## PR Status : - Overall Status : Done - Commits : Done - Synced to base (Collapse:main) : Yes - Build status : OK - Crashing : Yes - Bug found caused by PR : 0 ### Templates <details> <summary>Changelog Prefixes</summary> ``` **[New]** **[Imp]** **[Fix]** **[Loc]** **[Doc]** ``` </details>
2 parents bbf9729 + e3d83c0 commit 258bd46

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

CollapseLauncher/XAMLs/MainApp/ValueConverters.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -718,7 +718,7 @@ await CacheManager
718718
CancellationToken.None);
719719

720720
resultStream = result.Stream;
721-
using IRandomAccessStream stream = resultStream.AsRandomAccessStream(true);
721+
IRandomAccessStream stream = resultStream.AsRandomAccessStream(true);
722722
image.ImageOpened += ImageOnImageOpened;
723723

724724
await image.SetSourceAsync(stream);

0 commit comments

Comments
 (0)