[crossfire] Volunteer for Windows builds?

Nicolas Weeger nicolas.weeger at laposte.net
Fri Feb 8 15:12:25 CST 2008


> I will have limited access to a 32bit Win XP home workstation starting
> in about 2 weeks.
>
> Will Visual Studio express work for the builds?
> Or, is something else needed or recommended?

I'm not totally sure, I only tried with VS 6...

Note that it will *NOT* work with Visual Studio 2008. There is a workaround to 
temporarily solve the issue, but it's not guaranteed it won't crash horribly 
at some point.

Technical details: VS2008 apparently changed the behaviour of snprintf, which 
will happily not add a final NULL when the destination buffer is not big 
enough. Crossfire relies on the presence of a final NULL and uses strlen 
after such concatenation... The result under Windows is dirty, obviously :p
One fix is to increase the buffer sizes everywhere and hope you'll never try 
to put larger text.
Other solution (better) is to use StringBuffer for concatenation, which 
requires some work on the code... (something I have in mind, but not sure 
when it'll be done).
(note that there may be some other function or compile flag I'm missing, I 
didn't test everything...)


Also, for Windows builds, the "hard" part is the initial setup. Once 
everything is installed, building isn't too hard.

Nicolas
-- 
http://nicolas.weeger.org [Petit site d'images, de textes, de code, bref de 
l'aléatoire !]



More information about the crossfire mailing list