Skip to content

Commit

Permalink
pps: initialize ts_real properly
Browse files Browse the repository at this point in the history
Initialize ts_real.flags to fix compiler warning about possible
uninitialized use of this field.

Signed-off-by: Alexander Gordeev <lasaine@lvk.cs.msu.su>
Cc: john stultz <johnstul@us.ibm.com>
Cc: Rodolfo Giometti <giometti@linux.it>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
  • Loading branch information
ago authored and torvalds committed Feb 25, 2011
1 parent e5598f8 commit 99b0d36
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/pps/kapi.c
Original file line number Diff line number Diff line change
Expand Up @@ -168,7 +168,7 @@ void pps_event(struct pps_device *pps, struct pps_event_time *ts, int event,
{
unsigned long flags;
int captured = 0;
struct pps_ktime ts_real;
struct pps_ktime ts_real = { .sec = 0, .nsec = 0, .flags = 0 };

/* check event type */
BUG_ON((event & (PPS_CAPTUREASSERT | PPS_CAPTURECLEAR)) == 0);
Expand Down

0 comments on commit 99b0d36

Please sign in to comment.