Skip to content

Commit

Permalink
stm32f4: random fix sign-compare
Browse files Browse the repository at this point in the history
  • Loading branch information
Joakim Gebart committed May 29, 2015
1 parent a7d7e2b commit 00367ab
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions cpu/stm32f4/periph/random.c
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ int random_read(char *buf, unsigned int num)
{
/* cppcheck-suppress variableScope */
uint32_t tmp;
int count = 0;
unsigned int count = 0;

while (count < num) {
/* wait for random data to be ready to read */
Expand All @@ -48,7 +48,7 @@ int random_read(char *buf, unsigned int num)
}
}

return count;
return (int)count;
}

void random_poweron(void)
Expand Down

0 comments on commit 00367ab

Please # to comment.