Debian Codegraph @

debian/patches/CVE-2026-76041

raw
1 From 5e4f3217c17a8d88195d4c2924613420a256457b Mon Sep 17 00:00:00 2001
2 From: Michael Ludwig <[email protected]>
3 Date: Tue, 4 Aug 2026 14:39:10 -0400
4 Subject: [PATCH] [ganesh] Check result inside GrResourceProvider::writePixels
5
6 Bug: https://issues.chromium.org/issues/540027341
7 Fixed: 540027341
8 Change-Id: Icde9d077dfb3ec3cdb7a6e775c6472443dba8781
9 Reviewed-on: https://skia-review.googlesource.com/c/skia/+/1315336
10 Auto-Submit: Michael Ludwig <[email protected]>
11 Reviewed-by: Robert Phillips <[email protected]>
12 Commit-Queue: Robert Phillips <[email protected]>
13 ---
14 src/gpu/ganesh/GrResourceProvider.cpp | 14 ++++++++------
15 1 file changed, 8 insertions(+), 6 deletions(-)
16
17 diff --git a/src/gpu/ganesh/GrResourceProvider.cpp b/src/gpu/ganesh/GrResourceProvider.cpp
18 index 6ecf6bbd47..9149cbd1e8 100644
19 --- a/src/gpu/ganesh/GrResourceProvider.cpp
20 +++ b/src/gpu/ganesh/GrResourceProvider.cpp
21 @@ -922,11 +922,13 @@ sk_sp<GrTexture> GrResourceProvider::writePixels(sk_sp<GrTexture> texture,
22 if (tempColorType == GrColorType::kUnknown) {
23 return nullptr;
24 }
25 - SkAssertResult(fGpu->writePixels(texture.get(),
26 - SkIRect::MakeSize(baseSize),
27 - colorType,
28 - tempColorType,
29 - tmpTexels.get(),
30 - mipLevelCount));
31 + if (!fGpu->writePixels(texture.get(),
32 + SkIRect::MakeSize(baseSize),
33 + colorType,
34 + tempColorType,
35 + tmpTexels.get(),
36 + mipLevelCount)) {
37 + return nullptr;
38 + }
39 return texture;
40 }
41 --
42 2.53.0
43