Author: tcort
Date: Mon Mar 16 23:38:45 2009
New Revision: 5580
URL: http://svn.gna.org/viewcvs/pokersource?rev=5580&view=rev
Log:
For some strange reason 'valgrind' says I'm doing a 'Conditional jump or
move depends on uninitialised value(s)' when I qsort() a dynamically
sized array. Example,
int ncombinations = 21;
ipp_message *combinations[ncombinations];
...
qsort(combinations, ncombinations, sizeof(ipp_message *),
ipp_hand_compar);
Doing the same thing with a staticly sized array doesn't give the
error. Example,
int ncombinations = 21;
ipp_message *combinations[21];
...
qsort(combinations, ncombinations, sizeof(ipp_message *),
ipp_hand_compar);
Therefore this patch makes the array statically sized to appease the
valgrind gods. Hopefully, you won't have to change your ssh host keys
after this one ;)
Modified:
trunk/tinypoker/libtinypoker/src/main/tinypoker.c
_______________________________________________
Pokersource-commits mailing list
[email protected]
https://mail.gna.org/listinfo/pokersource-commits