[GRASS-dev] [bug #5003] (grass) r.series won't compile with Sun C 5.5.

this bug's URL: http://intevation.de/rt/webrt?serial_num=5003
-------------------------------------------------------------------------

Subject: r.series won't compile with Sun C 5.5.

Platform: Solaris2.x/Sparc
grass obtained from: Trento Italy site
grass binary for platform: Compiled from Sources
GRASS Version: cvs 20060815

When compiling GRASS with Sun C 5.5, file c_percentile.c in r.series fails with the following errors:

"c_percentile.c", line 29: void function cannot return value
"c_percentile.c", line 34: void function cannot return value
"c_percentile.c", line 39: void function cannot return value

Each of these lines tries to return a value from a function returning void with the pretext that they are trying to return a void gotten from another function. Even if this works with some compilers, I fail to see the logic behind. If the return-statements from the failing lines are removed, everything compiles fine. I can see no logical reason not to.

Harri K.

-------------------------------------------- Managed by Request Tracker

Request Tracker wrote:

this bug's URL: http://intevation.de/rt/webrt?serial_num=5003
-------------------------------------------------------------------------

Subject: r.series won't compile with Sun C 5.5.

Platform: Solaris2.x/Sparc
grass obtained from: Trento Italy site
grass binary for platform: Compiled from Sources
GRASS Version: cvs 20060815

When compiling GRASS with Sun C 5.5, file c_percentile.c in r.series fails with the following errors:

"c_percentile.c", line 29: void function cannot return value
"c_percentile.c", line 34: void function cannot return value
"c_percentile.c", line 39: void function cannot return value

Each of these lines tries to return a value from a function returning
void with the pretext that they are trying to return a void gotten
from another function. Even if this works with some compilers, I fail
to see the logic behind. If the return-statements from the failing
lines are removed, everything compiles fine. I can see no logical
reason not to.

Fixed in CVS.

--
Glynn Clements <glynn@gclements.plus.com>