1
0
mirror of https://github.com/esp8266/Arduino.git synced 2025-07-30 16:24:09 +03:00

Changing recv() to return signed int16 (in Ethernet socket.cpp). S. Wallace

http://code.google.com/p/arduino/issues/detail?id=516
This commit is contained in:
David A. Mellis
2011-12-08 17:29:28 -05:00
parent 597da2e45d
commit 7c90d9d8b5
2 changed files with 3 additions and 3 deletions

View File

@ -143,10 +143,10 @@ uint16_t send(SOCKET s, const uint8_t * buf, uint16_t len)
*
* @return received data size for success else -1.
*/
uint16_t recv(SOCKET s, uint8_t *buf, uint16_t len)
int16_t recv(SOCKET s, uint8_t *buf, int16_t len)
{
// Check how much data is available
uint16_t ret = W5100.getRXReceivedSize(s);
int16_t ret = W5100.getRXReceivedSize(s);
if ( ret == 0 )
{
// No data available.