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

Add example for plain STOMP connection #240

Merged
merged 2 commits into from Sep 25, 2017
Merged

Conversation

mgbckr
Copy link
Contributor

@mgbckr mgbckr commented Sep 25, 2017

Making a plain STOMP connection work (without SockJS, cf. #216) was a little tricky since STOMP messages are NULL terminated. That is, arduinoWebSockets determines the payload length via std::strlen() thus dropping the required NULL character. The solution is to pass the incremented (+1) length of a NULL terminated String instead of its original length. While this seems obvious, for me, it took some time to figure this out. I added an example to keep others from spending as much time one this as I did ;)

@Links2004
Copy link
Owner

example's are always welcome

@Links2004 Links2004 merged commit 9608c2d into Links2004:master Sep 25, 2017
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

Successfully merging this pull request may close these issues.

None yet

2 participants