diff options
author | Eric S. Raymond <esr@thyrsus.com> | 2010-03-31 19:19:24 -0400 |
---|---|---|
committer | Eric S. Raymond <esr@thyrsus.com> | 2010-03-31 19:19:24 -0400 |
commit | 2a27bea64b936dffe687ed38f210dddc3ccfc681 (patch) | |
tree | d4535f6d40e06961ab6d29cf167654da2a761932 /packet.c | |
parent | 4acdd7a9436153ab7ee036a935ee1abb30bcabb0 (diff) | |
download | gpsd-2a27bea64b936dffe687ed38f210dddc3ccfc681.tar.gz |
Factor out a little function to initiaslize the packet tester properly.
Diffstat (limited to 'packet.c')
-rw-r--r-- | packet.c | 6 |
1 files changed, 6 insertions, 0 deletions
@@ -1021,6 +1021,12 @@ static void character_discard(struct gps_packet_t *lexer) /* entry points begin here */ +void packet_init(struct gps_packet_t *lexer) +{ + lexer->char_counter = 0; + lexer->retry_counter = 0; +} + void packet_parse(struct gps_packet_t *lexer) /* grab a packet from the input buffer */ { |