diff options
| author | Masoud Naservand <[email protected]> | 2023-10-09 11:17:54 +0330 |
|---|---|---|
| committer | GitHub <[email protected]> | 2023-10-09 09:47:54 +0200 |
| commit | d309b1eaa7712dc0d15431bfb6efc0508e6ecbc8 (patch) | |
| tree | 933529141449e9cb8ead616275889d7b2d55a771 /src | |
| parent | ea9de852bdc6b6867fdf2805e6c5caf476b61bde (diff) | |
| download | raylib-d309b1eaa7712dc0d15431bfb6efc0508e6ecbc8.tar.gz raylib-d309b1eaa7712dc0d15431bfb6efc0508e6ecbc8.zip | |
Call nsvgDeleteRasterizer() on created rasterizer (#3392)
the `NSVGrasterizer *rast` needs to be passed
to nsvgDeleteRasterizer() when we are done with it.
Diffstat (limited to 'src')
| -rw-r--r-- | src/rtextures.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/rtextures.c b/src/rtextures.c index fa8d91ea..dc7f4af0 100644 --- a/src/rtextures.c +++ b/src/rtextures.c @@ -384,6 +384,7 @@ Image LoadImageSvg(const char *fileNameOrString, int width, int height) // Free used memory nsvgDelete(svgImage); + nsvgDeleteRasterizer(rast); } if (isSvgStringValid && (fileData != fileNameOrString)) UnloadFileData(fileData); @@ -555,6 +556,7 @@ Image LoadImageFromMemory(const char *fileType, const unsigned char *fileData, i image.format = PIXELFORMAT_UNCOMPRESSED_R8G8B8A8; nsvgDelete(svgImage); + nsvgDeleteRasterizer(rast); } } #endif |
