diff options
author | unknown <df@kahlann.erinye.com> | 2007-01-27 22:07:52 +0100 |
---|---|---|
committer | unknown <df@kahlann.erinye.com> | 2007-01-27 22:07:52 +0100 |
commit | d5ada3e15d7e5505140be9ba8a26e9c9d40b5fed (patch) | |
tree | b6f69bf491dae22ff9db35e679d916f66e2c432b /dbug/factorial.c | |
parent | 20e5e1d2fb748b43e672698dc5bbc816d00593f5 (diff) | |
download | mariadb-git-d5ada3e15d7e5505140be9ba8a26e9c9d40b5fed.tar.gz |
Build fix for sunfire100b. This can go when BUG#14420 is fixed.
dbug/dbug.c:
Build fix for sunfire100b. The ld does not want to link with an empty library, so we put something in it.
dbug/factorial.c:
Build fix for sunfire100b. When DBUG_OFF is defined, dbug is not there, and we can't use it even if we try, period.
Diffstat (limited to 'dbug/factorial.c')
-rw-r--r-- | dbug/factorial.c | 14 |
1 files changed, 12 insertions, 2 deletions
diff --git a/dbug/factorial.c b/dbug/factorial.c index 56197aef29e..7b190ea8d8e 100644 --- a/dbug/factorial.c +++ b/dbug/factorial.c @@ -1,6 +1,13 @@ #ifdef DBUG_OFF /* We are testing dbug */ -#undef DBUG_OFF -#endif + +int factorial(register int value) { + if(value > 1) { + value *= factorial(value-1); + } + return value; +} + +#else #include <my_global.h> @@ -15,3 +22,6 @@ register int value) DBUG_PRINT ("result", ("result is %d", value)); DBUG_RETURN (value); } + +#endif + |