bugfix: ' floating point exception' due wrongly placed code while integrating the old 'getSqrt()' function into the 'bsqrt()' function i misplaced some code. this lead to 'r' being 0 on the first run. doh.
Mathias Gumz akira at fluxbox dot org
1 files changed,
2 insertions(+),
1 deletions(-)
jump to
M
src/FbTk/TextureRender.cc
→
src/FbTk/TextureRender.cc
@@ -76,9 +76,10 @@ if (sqrt_table[0] == 1) {
sqrt_table[0] = 0; sqrt_table[1] = 1; - unsigned long r = x >> 1; + unsigned long r; unsigned long q; for (x = 2; x < SQRT_TABLE_ENTRIES; x++) { + r = x >> 1; while (1) { q = x / r; if (q >= r) {