-
Notifications
You must be signed in to change notification settings - Fork 2.1k
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
Fix crashes in XMPPvCardTempEmail and XMPPvCardTempTel initialize #1162
Fix crashes in XMPPvCardTempEmail and XMPPvCardTempTel initialize #1162
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks! This looks great.
Do you think you could use XMLElement
instead of DDXMLElement
?
|
||
import XCTest | ||
import XMPPFramework | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
import KissXML
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Seems like I don't have to import anything at all.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah yeah, it's probably implicitly re-exported by XMPPFramework.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oh, hm that's weird that you don't even need to import XMPPFramework.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, I also don't really understand why. :)
O yes, sure, didn't know about the |
Awesome, thank you! |
Fixes #1050 and #1118.
Setter methods in
XMPPcVardTempEmail
andXMPPcVardTempTel
had typing mistakes. Must have been happened sometime during 3.7 to 4.0 transition.These types do not allow adding properties, that's why the allocated size is compared to the size of
NSXMLElement
ininitialize
.Every added property has to have matching get and set overwrites, otherwise ObjC will allocate memory for the property and the size check will fail.
The linked issue describe that behavior.
I also added missing implementation for
TEL
and few tests forXMPPvCardTemp
.