lwip-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [lwip-devel] Code cleanups for 1.4.0


From: address@hidden
Subject: Re: [lwip-devel] Code cleanups for 1.4.0
Date: Mon, 28 Jun 2010 21:13:19 +0200
User-agent: Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10.6; de; rv:1.9.2.4) Gecko/20100608 Thunderbird/3.1

 Bill Auerbach wrote:
#define SNMP_ASN1_CONSTR (0x20)
#define SNMP_ASN1_PRIMIT (!0x20)
To me, these two lines suggest the same as Bill said: 0x20 is the constant, and CONSTR has turned the bit on, while PRIMIT has turned it off. I'd vote for removing them (and replacing them with the lines below). Comments aren't even necessary, to me. Although, a hint to the corresponding RFC (or whatever defined the bits) would have been nice in the first place...
#define SNMP_ASN1_UNIV   (0)
#define SNMP_ASN1_APPLIC (0x40)
#define SNMP_ASN1_CONTXT (0x80)

#define SNMP_ASN1_CONSTR (0x20)
#define SNMP_ASN1_PRIMIT (0)
I think that's good enough.

Simon



reply via email to

[Prev in Thread] Current Thread [Next in Thread]