Russell Suter wrote:

Andy Ross wrote:

Instead, try this as a more verbose variant and see if it works.  It
adds an explicit cast to the type of the table, and uses a char* to
get around the original error:

h->table = (struct HashNode**)(((char*)h->nodes) + sz*sizeof(struct
HashNode));

You could do this but using again what you said about pointer arithmetic it
can be reduced to:

h->table = (struct HashNode**) (h->nodes + sz);

You must have the parens around the addition since the cast has a
higher precedence.

Both seem to work well (in which case I prefer the later solution).
But then I get a problem with the test.nas script which runs fine from 0 to 93 and then seems to hang ...


Erik


_______________________________________________ Flightgear-devel mailing list [EMAIL PROTECTED] http://mail.flightgear.org/mailman/listinfo/flightgear-devel

Reply via email to