joyent/node — Issue #2608: dgram.send callback returns input buffer length rather than actual bytes sent
Author: acd
Created: 2012-01-25 04:28:51+00:00
State: open

Hi,

I noticed that the dgram.send callback returns the size of the buffer provided to send rather than the actual count of bytes sent. I've patched my local branch of node to handle this correctly by grabbing the status from uv_udp_send_t however I'm not sure if this is completely safe since I have little familiarity with the node codebase. I'm also not sure if req->status is set to the number of bytes sent on the Windows side of libuv -- doesn't seem to.

Anyhow, figured I'd mention it. A commit of my change can be found below...

https://github.com/acd/node/commit/406c1f753e4861d5dcf0676c5b95e0eee986afb3