Skip to content

Commit

Permalink
drivers/net/wan/pc300_drv: fix bug caught by gcc warning
Browse files Browse the repository at this point in the history
The warning

drivers/net/wan/pc300_drv.c: In function ‘cpc_open’:
drivers/net/wan/pc300_drv.c:2942: warning: ‘br’ may be used
uninitialized in this function

was valid.  Ensure 'br' is initialized in all cases.

Signed-off-by: Jeff Garzik <jeff@garzik.org>
  • Loading branch information
Jeff Garzik committed Jul 17, 2007
1 parent ae97fec commit 79c63e1
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions drivers/net/wan/pc300_drv.c
Original file line number Diff line number Diff line change
Expand Up @@ -2833,6 +2833,8 @@ static int clock_rate_calc(uclong rate, uclong clock, int *br_io)
int br, tc;
int br_pwr, error;

*br_io = 0;

if (rate == 0)
return (0);

Expand Down

0 comments on commit 79c63e1

Please sign in to comment.