Re: [EXIM] Debug wishlist.

Top Page
Delete this message
Reply to this message
Author: Piete Brooks
Date:  
To: Adrian Bool
CC: Sherwood Botsford, Exim List
Subject: Re: [EXIM] Debug wishlist.
>> I've found some programs that debug instead of being monotonic,
>> works by flags.


AKA bit masks ..

>> 1=file opens
>> 2=dbm searches
>> 4=changining euid/egid
>> 10=SMTP transaction
>> 20=DNS lookups
>> 40=local delivery
>> 100=...
> If you go for,
> 1=file opens
> 2=dbm searches
> 4=changining euid/egid
> 8=SMTP transaction
> 16=DNS lookups
> 32=local delivery
> 64=...
> Then you can turn on any combination...


Methinks the former list is in octal, and the latter in decimal -- perchance?
:-)

I would have used Hex :-))

> Kinda limits you to 31 catagories though...


Well, 32 on most machines ...

I remember decades ago using IBM 360 Assembler Macros to implement the above.
In fact I seem to remeber reading some written by a certain PH10 which allowed
the use of more than 32 bits ... I'm sure he can do it in C too :-))
After all, all the user sees is the docunentation describing how to set it
("-d <number>") and so long as exim doesn't try anything silly like
atoi() on it, it can set bits in multiple different flag words
(which can be 16, 32 or 64 bits long), although for sanity it might be best
to specify that the number is in hex (or octal).
[[ but it would be nice if it had a "special case" of "-1" which means
"set all bits" -- I tend to use that a lot when debugging my own code
]]

--
*** Exim information can be found at http://www.exim.org/ ***