ARMmbed / ARMmbed/sockets

TCPStream issues

Open
#54 2 comments 0 reactions 0 assignees View on GitHub
mirrored
Dominant language
C++
Stars
6
Forks
18
PR merge metrics
No merged PRs in 30d

Description

1. When instantiating the class using the constructor:
TCPStream(const socket_stack_t stack);

there is no guarantee of a valid api being set. Thus if the connect method is then used, _socket.api
could be NULL. Should check this within the connect method.
If this is added then the method header should be updated accordingly.
2. Similarly for the setNagle() method. _socket.api could be invoked with a NULL value.
Also setNagle calls set_option() which returns an error type which is then ignored. Shouldn't this
error type be forwarded up to the caller of the method?

Contributor guide

No contributing guide indexed for this repository

Research direction

Locate the TCPStream constructor, connect(), setNagle(), and the set_option() call. Trace how _socket.api is initialized and how errors are represented, then verify that null API cases and set_option() failures are handled consistently and that any affected method header reflects the behavior.

Written by the indexing model from the issue text.

Assessment

Tech stack
cpp
Domain
networking
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
38/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.