mirror of
https://github.com/zoriya/react-native-svg.git
synced 2026-06-08 09:10:44 +00:00
[iOS] Fix group auto release and path release.
This commit is contained in:
@@ -135,7 +135,7 @@
|
||||
return YES;
|
||||
}];
|
||||
|
||||
cached = CGPathRetain(path);
|
||||
cached = CGPathRetain(CFAutorelease(path));
|
||||
self.path = cached;
|
||||
return cached;
|
||||
}
|
||||
|
||||
@@ -78,6 +78,7 @@ CGFloat const RNSVG_DEFAULT_FONT_SIZE = 12;
|
||||
|
||||
- (void)clearPath
|
||||
{
|
||||
CGPathRelease(_path);
|
||||
self.path = nil;
|
||||
}
|
||||
|
||||
@@ -546,6 +547,7 @@ CGFloat const RNSVG_DEFAULT_FONT_SIZE = 12;
|
||||
{
|
||||
CGPathRelease(_cachedClipPath);
|
||||
CGImageRelease(_clipMask);
|
||||
CGPathRelease(_path);
|
||||
_clipMask = nil;
|
||||
}
|
||||
|
||||
|
||||
@@ -40,6 +40,7 @@
|
||||
if (self.dirty || self.merging) {
|
||||
return;
|
||||
}
|
||||
_srcHitPath = nil;
|
||||
[super invalidate];
|
||||
self.dirty = true;
|
||||
}
|
||||
@@ -155,7 +156,6 @@
|
||||
|
||||
- (void)dealloc
|
||||
{
|
||||
self.path = nil;
|
||||
CGPathRelease(_hitArea);
|
||||
CGPathRelease(_strokePath);
|
||||
_sourceStrokeDashArray = nil;
|
||||
|
||||
Reference in New Issue
Block a user