shell: use min() macro
This commit is contained in:
parent
e9a9236fc7
commit
1188b24a31
1 changed files with 1 additions and 1 deletions
|
@ -157,7 +157,7 @@ static void do_flash_write(const char *s)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
while (len) {
|
while (len) {
|
||||||
nbytes = (len > 256) ? 256 : len;
|
nbytes = min(len, 256);
|
||||||
parse_hex(stdin, buf, nbytes);
|
parse_hex(stdin, buf, nbytes);
|
||||||
printf("\n");
|
printf("\n");
|
||||||
print_hex_ascii(buf, nbytes);
|
print_hex_ascii(buf, nbytes);
|
||||||
|
|
Loading…
Add table
Reference in a new issue