Minor code cleanup of Cooja log
@@ -130,14 +130,9 @@ dbg_putchar(int c)
unsigned int
dbg_send_bytes(const unsigned char *s, unsigned int len)
{
- unsigned int i = 0;
-
- while(s && *s != 0) {
- if(i >= len) {
- break;
- }
+ unsigned int i;
+ for(i = 0; i < len && s && *s != 0; i++) {
putchar(*s++);
- i++;
}
return i;
}
