The SVGStringFromCGPaths function causes the program to crash.
CodeForRabbit opened this issue · 2 comments
CodeForRabbit commented
When I use SVGBezierPath.SVGRepresentation to execution
This piece of code in SVGStringFromCGPaths crashed
float const alpha = CGColorGetAlpha((__bridge CGColorRef)pathAttrs[key]);
Because the value in pathAttrs[key] is a CGaffinetransfrom value, it is not correctly specified by if(! [pathAttrs[key] isKindOfClass:[NSString class]]), still entered the method
You can try the attached svg file
Have a nice day!
Specifications
- PocketSVG Version: 2.7.2
- Xcode Version:
- iOS/macOS Version:
arielelkin commented
Thanks for flagging this @CodeForRabbit
Could you please share the code you wrote that produces xthe crash?
CodeForRabbit commented
Sorry, I'm having problems with my own code. Your library works very well. Thank you for your work!