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

Crashes on Galileo when calling readHeader() or skipResponseHeaders() #10

Closed
mechalas opened this issue May 13, 2014 · 3 comments
Closed

Comments

@mechalas
Copy link

This library crashes on Galileo when you call skipResponseHeaders() or readHeader(). The issue is that readHeader() is doing this:

if (*iContentLengthPtr == c)

But this pointer gets initialized to 0 instead of kContentLengthPrefix in resetState(), so you are doing a check on a NULL pointer. On a true Arduino device this may not crash, but I bet it doesn't work like it's intended.

The fix is to initialize iContentLengthPtr correctly in resetState():

iContentLengthPtr= kContentLengthPrefix;

@briandbl
Copy link

briandbl commented Oct 6, 2014

i try your way, but i have the crash question. can you really run well on Galileo board?

@mechalas
Copy link
Author

Yes, this really does run on Galileo if you make this change.

Are you sure your crash is due to this issue, and not some other problem?

@amcewen
Copy link
Owner

amcewen commented Jul 3, 2015

Fix released in version 2.2.0, which should soon be available via the new Arduino library manager

@amcewen amcewen closed this as completed Jul 3, 2015
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

3 participants