metajack / libstrophe

The libstrophe repository has moved to https://github.com/strophe/libstrophe
http://strophe.im/libstrophe
Other
135 stars 49 forks source link

A parameter of xmpp_conn_t is not initialized. #13

Closed curse666 closed 12 years ago

curse666 commented 12 years ago

Hi everyone.

Thank you for create this library. This is great help for our project.

I had experienced a bug which caused by this library. The bug was brought by Initialization leak of "state" of xmpp_conn_t structure. Architecture of memory allocation of our environment allocates memory with not initialized value. So undefined behavior sometimes occurred.

We solved this problem by initializing "state" by "XMPP STATE DISCONNECTED" in "xmpp_conn_new" function.

Thanks.