Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CLImageEditor in my self Static Library #74

Closed
mrgaolei opened this issue Nov 26, 2014 · 4 comments
Closed

CLImageEditor in my self Static Library #74

mrgaolei opened this issue Nov 26, 2014 · 4 comments

Comments

@mrgaolei
Copy link

I'm creating my self Static Library to other developers, in my Static Library include CLImageEditor.
I integration CLImageEditor use Cocopods to my Static Library and compile successful.
But when I test to use my Static Library in other app, the app crashed.
Crash code line is
CLImageEditor *editor = [[CLImageEditor alloc] initWithImage:someimage];

Crash report is
2014-11-26 16:46:44.910 M6Test[43931:2825881] * Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '* -[**NSPlaceholderDictionary initWithObjects:forKeys:count:]: attempt to insert nil object from objects[1]'
* First throw call stack:
(
0 CoreFoundation 0x000000011027ff35 __exceptionPreprocess + 165
1 libobjc.A.dylib 0x000000010fb6bbb7 objc_exception_throw + 45
2 CoreFoundation 0x000000011018b61f -[__NSPlaceholderDictionary initWithObjects:forKeys:count:] + 383
3 CoreFoundation 0x000000011019e64b +[NSDictionary dictionaryWithObjects:forKeys:count:] + 59
4 M6Test 0x000000010f43a27d +[CLDefaultEmptyFilter defaultFilterInfo] + 329
5 M6Test 0x000000010f43b5a5 +[CLDefaultEmptyFilter defaultInfoForKey:] + 59
6 M6Test 0x000000010f43b6a8 +[CLDefaultEmptyFilter isAvailable] + 63
7 M6Test 0x000000010f440d29 +[CLImageToolInfo(Private) toolInfoForToolClass:] + 66
8 M6Test 0x000000010f440fca +[CLImageToolInfo(Private) toolsWithToolClass:] + 316
9 M6Test 0x000000010f440e13 +[CLImageToolInfo(Private) toolInfoForToolClass:] + 300
10 M6Test 0x000000010f440fca +[CLImageToolInfo(Private) toolsWithToolClass:] + 316
11 M6Test 0x000000010f440e13 +[CLImageToolInfo(Private) toolInfoForToolClass:] + 300
12 M6Test 0x000000010f454ca0 -[_CLImageEditorViewController initWithNibName:bundle:] + 128
13 M6Test 0x000000010f454d36 -[_CLImageEditorViewController initWithImage:delegate:] + 58
14 M6Test 0x000000010f43fbb4 -[CLImageEditor initWithImage:delegate:] + 89
15 M6Test 0x000000010f41408c -[M6MainViewController editImage:] + 189
16 UIKit 0x00000001110268be -[UIApplication sendAction:to:from:forEvent:] + 75
17 UIKit 0x000000011112d410 -[UIControl _sendActionsForEvents:withEvent:] + 467
18 UIKit 0x000000011112c7df -[UIControl touchesEnded:withEvent:] + 522
19 UIKit 0x000000011106c308 -[UIWindow _sendTouchesForEvent:] + 735
20 UIKit 0x000000011106cc33 -[UIWindow sendEvent:] + 683
21 UIKit 0x00000001110399b1 -[UIApplication sendEvent:] + 246
22 UIKit 0x0000000111046a7d _UIApplicationHandleEventFromQueueEvent + 17370
23 UIKit 0x0000000111022103 _UIApplicationHandleEventQueue + 1961
24 CoreFoundation 0x00000001101b5551 __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE0_PERFORM_FUNCTION
+ 17
25 CoreFoundation 0x00000001101ab41d __CFRunLoopDoSources0 + 269
26 CoreFoundation 0x00000001101aaa54 __CFRunLoopRun + 868
27 CoreFoundation 0x00000001101aa486 CFRunLoopRunSpecific + 470
28 GraphicsServices 0x00000001163e99f0 GSEventRunModal + 161
29 UIKit 0x0000000111025420 UIApplicationMain + 1282
30 M6Test 0x000000010f40fda3 main + 115
31 libdyld.dylib 0x0000000112f3d145 start + 1
32 ??? 0x0000000000000001 0x0 + 1
)
libc++abi.dylib: terminating with uncaught exception of type NSException
(lldb)

@yackle
Copy link
Owner

yackle commented Nov 26, 2014

Do you include CLImageEditor.bundle to your library?

@mrgaolei
Copy link
Author

Because I include CLImageEditor use Cocoapods, so CLImageEditor.bundle is sure in my Static Library.
I reconfirm it just now.
Have you any other idea to resolve this problem?

@yackle
Copy link
Owner

yackle commented Nov 26, 2014

I have no other ideas. I think it is necessary to include the bundle to the main project instead of the static library.

@mrgaolei
Copy link
Author

Yes, I solve this by include this bundle to the main project.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants