App terminated on rotation in [SchartCanvas viewAboutToRotate]


#1

Hi,

I have an app which uses ShinobiControls v. 2.5.6 Premium. I am adding a label to the canvas. 
Now here is the thing … normally it workes ok… but I got an Exception which terminated the app.

0

Crashed: com.apple.main-thread
EXC_BAD_ACCESS KERN_INVALID_ADDRESS at 0x0000000c

 

Stack trace below:

Thread : Crashed: com.apple.main-thread

0  libobjc.A.dylib                0x39d0f626 objc_msgSend + 5

1  MyApp                    0x004fbc7d -[SChartCanvas viewAboutToRotate] + 148

2  CoreFoundation                 0x2f01e1f1 __CFNOTIFICATIONCENTER_IS_CALLING_OUT_TO_AN_OBSERVER__ + 12

3  CoreFoundation                 0x2ef9257f _CFXNotificationPost + 1718

4  Foundation                     0x2f97ca3d -[NSNotificationCenter postNotificationName:object:userInfo:] + 76

5  UIKit                          0x3187da33 -[UIDevice setOrientation:animated:] + 294

6  UIKit                          0x3187cf0f -[UIApplication handleEvent:withNewEvent:] + 1498

7  UIKit                          0x3187c871 -[UIApplication sendEvent:] + 72

8  UIKit                          0x318e0cc9 _UIApplicationHandleEvent + 616

9  GraphicsServices               0x33ec3aed _PurpleEventCallback + 608

10 GraphicsServices               0x33ec36d7 PurpleEventCallback + 34

11 CoreFoundation                 0x2f026ab7 __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE1_PERFORM_FUNCTION__ + 34

12 CoreFoundation                 0x2f026a53 __CFRunLoopDoSource1 + 346

13 CoreFoundation                 0x2f025227 __CFRunLoopRun + 1398

14 CoreFoundation                 0x2ef8ff4f CFRunLoopRunSpecific + 522

15 CoreFoundation                 0x2ef8fd33 CFRunLoopRunInMode + 106

16 GraphicsServices               0x33ec2663 GSEventRunModal + 138

17 UIKit                          0x318db16d UIApplicationMain + 1136

18 MyApp                0x000b18a9 main (main.m:17)

Is this a bug and is it know’n? Is there any solution to this problem?
Thx in advance.


#2

Hi okipol,

Thanks for getting in touch!

This isn’t a known issue with our charts.

Is it possible for you to send us a sample project showing your issue to info@shinobicontrols.com referencing this forum post?

This would really help us identify the source of your issue.

Kind Regards,
Andrew Polkinghorn


#3

Hi MrAPolk,

was that bug fixed, because I’ve got the same error with the  2.7.3.hotfix1-1 ?

Thanks,
Nick

#4

Hi Nfloussov,

I don’t think we’ve managed to replicate this issue on our side yet. Would it be possible for you to send us a small sample application that demonstrates this issue? You can email it to info@shinobicontrols.com referencing this forum post, and we’ll take a look and get back to you.

Thanks,
Jan Akerman


#5

Unfortunately the app is quite big.

Crashlog is aproximately the same as from okipol although the SC version is 2.7.3 hotfix1-1 :

Fatal Exception: NSInvalidArgumentException -[CALayerArray rotatesOnDeviceRotation]: unrecognized selector sent to instance 0x1af1c9d0 -[SChartCanvas viewAboutToRotate] Thread : Fatal Exception: NSInvalidArgumentException 0 CoreFoundation 0x254ab49f __exceptionPreprocess + 126 1 libobjc.A.dylib 0x32fdec8b objc_exception_throw + 38 2 CoreFoundation 0x254b08b9__ methodDescriptionForSelector 3 CoreFoundation 0x254ae7d7 ___forwarding___ + 714 4 CoreFoundation 0x253e0058 _CF_forwarding_prep_0 + 24 5 MyBigApp 0x0043e9ab -[SChartCanvas viewAboutToRotate] + 302 6 CoreFoundation 0x25463c61 __CFNOTIFICATIONCENTER_IS_CALLING_OUT_TO_AN_OBSERVER__ + 12 7 CoreFoundation 0x253bf6d5 _CFXNotificationPost + 1784 8 Foundation 0x260f1189 -[NSNotificationCenter postNotificationName:object:userInfo:] + 72 9 UIKit 0x2896ea13 -[UIDevice setOrientation:animated:] + 318 10 UIKit 0x2896e7c3 -[UIApplication handleEvent:withNewEvent:] + 1566 11 UIKit 0x2896e0e1 -[UIApplication sendEvent:] + 72 12 UIKit 0x289d2fa1 _UIApplicationHandleEvent + 632 13 GraphicsServices 0x2c753679 _PurpleEventCallback + 528 14 GraphicsServices 0x2c7532c3 PurpleEventCallback + 34 15 CoreFoundation 0x25471573 __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE1_PERFORM_FUNCTION__ + 34 16 CoreFoundation 0x2547150f __CFRunLoopDoSource1 + 346 17 CoreFoundation 0x2546fb11__ CFRunLoopRun + 1608 18 CoreFoundation 0x253bd3c1 CFRunLoopRunSpecific + 476 19 CoreFoundation 0x253bd1d3 CFRunLoopRunInMode + 106 20 GraphicsServices 0x2c7520a9 GSEventRunModal + 136 21 UIKit 0x289ccfa1 UIApplicationMain + 1440 22 MyBigApp 0x0008513b main (main.m:16) 23 libdyld.dylib 0x3355eaaf start + 2

#6

Hi Nfloussov,

Thank you for this information.

After further investigation of the “viewAboutToRotate” method in our SChartCanvas class we still can’t see anything that would cause such a crash.

Are you doing anything specific when setting up your chart? Any information to help us reproduce your crash would be appreciated.

Could you replicate your crash in one of our sample apps and send it to us?

This would really help us identify the source of the issue.

Kind regards,
Andrew Polkinghorn


#7

Hi,

We have recently fixed an issue relating to messages being sent to SChartCanvas after it is dealloced that looks very similar to the above issue. 

Version ShinobiCharts 2.7.3.hotfix2 might be worth trying if you are seeing this issue. This is available for download from our Portal.

I hope that solves the problem you have been seeing, but don’t hesitate to get in touch if the issue persists! :slight_smile:

Thanks

Ryan