Hexadecimal / decimal chaos
Over the time I noticed that some troubleshooting and debugging tools show numbers in hex and some in decimal even for things that are traditionally hex, for example PID and TID. Then when getting data from one program I need to convert it to a different base for another tool. So over some time I was able to get the idea of what hex numbers usually are even if they don’t have hexadecimal ‘A’-'F’ in their digits. For example, in one log I got this output:
Parent changed to 393954
Although this number is valid hex number as well as decimal I had intuitive feeling that it was decimal… Checking source code of the tool revealed that it was output as decimal indeed.
I guess this feeling arouse because I just checked that most window handles that I have seen have the 4th zero digit:
Handle: 2801E6Handle: 110044Handle: 10052Handle: E01B6Handle: 602E2
- Dmitry Vostokov @ DumpAnalysis.org -