winspool/tests: Use 0xdeadbeef as magic Value

Andreas Mohr andi at rhlx01.fht-esslingen.de
Fri May 26 18:01:40 CDT 2006


Hi,

On Sat, May 27, 2006 at 12:35:02AM +0200, Detlef Riekenberg wrote:
> 
> I was using 0x00dead00 before, but Dmitry suggested 0xdeadbeef, as this
> is used in most Places in wine.

First, then you should really write it as such...

Second, why does it *ALWAYS* have to be 0xdeadbeef?
In that case there's quite some probability that you have to go on a
frantic search for the *actual* place that caused Wine to crash with
a 0xdeadbeef value that's being used *everywhere*...

(noooooo, of couuuuurse that never happened to me...)

[andi at rhlx01 wine]$ find 2>/dev/null|xargs cat 2>/dev/null|grep 0xdeadbeef|wc -l
1632

!!!

Some alternatives:

0xdeadbee0
.
.
.
0xdeadbee9
0xcafebabe
0xcafed00d
0xdeaddead
0xc001cafe

OK, as an invalid error value during winetests there is no way to mix it up,
but with vtable values and many, many other places that use it that *is*
an issue.

Andreas

-- 
No programming skills!? Why not help translate many Linux applications! 
https://launchpad.ubuntu.com/rosetta
(or alternatively buy nicely packaged Linux distros/OSS software to help
support Linux developers creating shiny new things for you?)



More information about the wine-devel mailing list