Fix return value for Print::write(const void *buffer, uint32 size)
Print::write(const void *buffer, uint32 size) always returns 0, which is against specification. This patch fixes it.
This commit is contained in:
parent
4021c32fdb
commit
3efde692e7
|
@ -60,6 +60,7 @@ size_t Print::write(const void *buffer, uint32 size) {
|
||||||
uint8 *ch = (uint8*)buffer;
|
uint8 *ch = (uint8*)buffer;
|
||||||
while (size--) {
|
while (size--) {
|
||||||
write(*ch++);
|
write(*ch++);
|
||||||
|
n++;
|
||||||
}
|
}
|
||||||
return n;
|
return n;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue