cangen: move scope of variable ret
... so that it can be used in other parts of the main() functions, too. Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>pull/386/head
parent
8fb0e954b3
commit
4b6f8d62dd
3
cangen.c
3
cangen.c
|
|
@ -172,6 +172,7 @@ int main(int argc, char **argv)
|
|||
|
||||
struct timespec ts;
|
||||
struct timeval now;
|
||||
int ret;
|
||||
|
||||
/* set seed value for pseudo random numbers */
|
||||
gettimeofday(&now, NULL);
|
||||
|
|
@ -485,8 +486,6 @@ resend:
|
|||
return 1;
|
||||
}
|
||||
if (polltimeout) {
|
||||
int ret;
|
||||
|
||||
/* wait for the write socket (with timeout) */
|
||||
ret = poll(&fds, 1, polltimeout);
|
||||
if (ret == 0 || (ret == -1 && errno != -EINTR)) {
|
||||
|
|
|
|||
Loading…
Reference in New Issue