Source bugs (found during compiling)

Aside from the hundreds of implicit typecast errors when compiling in Windows (some of them casting down to smaller types, potentially losing data and causing instability), there's some syntax/logic errors being caught by the compiler:

Compiling...
myglu.c
d:\sylphis3d\sylphis\trunk\runtime\src\sylphis\core\src\myglu.c(863) : warning C4553: '==' : operator has no effect; did you intend '='?
d:\sylphis3d\sylphis\trunk\runtime\src\sylphis\core\src\myglu.c(867) : warning C4553: '==' : operator has no effect; did you intend '='?
d:\sylphis3d\sylphis\trunk\runtime\src\sylphis\core\src\myglu.c(871) : warning C4553: '==' : operator has no effect; did you intend '='?

This code is:


/* iterators should be one byte past end */
if (!isTypePackedPixel(type)) {
iter2 == &oldimage[width*height*components];
}
else {
iter2 == &oldimage[width*height*
elements_per_group(format,0)];
}
iter == &((GLubyte *)userdata)[rowsize*height +
psm->pack_skip_rows * rowsize +
psm->pack_skip_pixels * group_size];

} /* else */

Can I patch code like this and somehow submit it, or is it best to simply post it here?


Hi Avaktar, Strange issue

Hi Avaktar,

Strange issue indeed. I don't believe I've ever seen this one mentioned in the forums before.

Most certainly you may fix the problem! (The fact that you can fix it is wonderful! I'm far from a programmer myself, so for any little problem I run across I go crawling to Harkal: fix please, fix.)

For patches, I believe the best method would be to report and issue in the bug tracker and attach the patch file. http://mantis.sylphis3d.com/

If that doesn't work for some reason, just posting it here should be fine.

-=Derek

Derek is right! all patches

Derek is right! all patches are welcome!! And mantis is the place for them (As long they are tested and reasonable!)
, along with some info.
As for the patch you say its correct... that statements don't pose a problem since it used to be assertions(!) ...
No need to send a patch since I committed the fix myself...