Skip to content

Let EthernetServer::write return the number of bytes written to any client #1699

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

Open
wants to merge 1 commit into
base: ide-1.5.x
Choose a base branch
from

Conversation

matthijskooijman
Copy link
Collaborator

Before, it would return the sum of the number of bytes written to all
clients, which makes it hard for a caller to find out the length of an
object printed (e.g., for alignment purposes). On the flipside, the
return value is now slightly less useful to detect connection errors,
but if really needed, something different should probably be implemented
anyway.

This change was discussed here:
http://comments.gmane.org/gmane.comp.hardware.arduino.devel/1928
http://forum.arduino.cc/index.php?topic=185835.0

…lient

Before, it would return the sum of the number of bytes written to all
clients, which makes it hard for a caller to find out the length of an
object printed (e.g., for alignment purposes). On the flipside, the
return value is now slightly less useful to detect connection errors,
but if really needed, something different should probably be implemented
anyway.
@matthijskooijman
Copy link
Collaborator Author

Btw, this pullreq is for 1.5, but the same patch applies unmodified to 1.0. I'm happy to supply another pullreq for that if that helps.

@matthijskooijman
Copy link
Collaborator Author

Any chance this could be merged? Or is there anything blocking this?

@ffissore ffissore added New and removed New labels Feb 27, 2014
@matthijskooijman matthijskooijman added Type: Bug Version: 1.5.x Library: Ethernet The Ethernet Arduino library and removed Component: Core Related to the code for the standard Arduino API labels Sep 10, 2014
@cmaglie cmaglie added this to the Release 1.5.8 milestone Sep 10, 2014
@cmaglie cmaglie modified the milestones: Release 1.5.9, Release 1.5.8 Oct 1, 2014
@cmaglie cmaglie modified the milestones: Release 1.6.0, Release 1.6.1 Feb 18, 2015
@ffissore ffissore modified the milestones: Release 1.6.1, Release 1.6.5 May 20, 2015
@ffissore ffissore modified the milestones: Release 1.6.5, Release 1.6.6 Jun 15, 2015
@ffissore ffissore removed this from the Release 1.6.6 milestone Nov 4, 2015
@agdl
Copy link
Member

agdl commented Jul 12, 2016

This issue was moved to arduino-libraries/Ethernet#35

@agdl agdl closed this Jul 12, 2016
@agdl
Copy link
Member

agdl commented Jul 12, 2016

Sorry closed by mistake

@agdl agdl reopened this Jul 12, 2016
@CLAassistant
Copy link

CLAassistant commented Apr 9, 2021

CLA assistant check
All committers have signed the CLA.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Library: Ethernet The Ethernet Arduino library Type: Bug
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants