From 55c10c503b359a4b6c2c3c392b1ee0a1a2c5172b Mon Sep 17 00:00:00 2001 From: Stephen Olesen Date: Tue, 30 Jun 2015 20:32:28 -0600 Subject: [PATCH] Some spacing, added header length minimum. --- AFSK.h | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/AFSK.h b/AFSK.h index 5d96c41..6c4d1dc 100644 --- a/AFSK.h +++ b/AFSK.h @@ -17,6 +17,7 @@ // This is with all the digis, two addresses, framing and full payload // Two more bytes are added for HDLC_ESCAPEs #define PACKET_MAX_LEN 512 +#define AX25_PACKET_HEADER_MINLEN 22 // HDLC framing bits #define HDLC_FRAME 0x7E @@ -48,7 +49,7 @@ public: void init(unsigned short dlen); inline void free() { if(freeData) - ::free(dataPtr); + ::free(dataPtr); } inline const unsigned char getByte(void) { return *readPos++; @@ -232,7 +233,7 @@ public: } inline bool txReady() volatile { if(encoder.isDone() && encoder.hasPackets()) - return true; + return true; return false; } inline bool isDone() volatile { return encoder.isDone(); } @@ -246,7 +247,7 @@ public: inline bool putTXPacket(Packet *packet) { bool ret = encoder.putPacket(packet); if(!ret) // No room? - PacketBuffer::freePacket(packet); + PacketBuffer::freePacket(packet); return ret; } inline Packet *getRXPacket() {