/*
sptps.c -- Simple Peer-to-Peer Security
- Copyright (C) 2011-2012 Guus Sliepen <guus@tinc-vpn.org>,
+ Copyright (C) 2011-2013 Guus Sliepen <guus@tinc-vpn.org>,
2010 Brandon L. Black <blblack@gmail.com>
This program is free software; you can redistribute it and/or modify
if(seqno > s->inseqno)
s->inseqno = seqno + 1;
+ if(!s->inseqno)
+ s->received = 0;
+ else
+ s->received++;
// Decrypt.
cipher_set_counter(&s->incipher, &seqno, sizeof seqno);