On Sat, Jan 20, 2001 at 02:53:22PM -0500, Hlady, Brian wrote:
> I'm using the code found on page 245 - 247 of Paul Dubois' book, MySQL. When
> I attempt to make it
> under Code Crusader, I get the error found below.
>
> gcc -g -Wall -Werror -I- -I. -I/usr/local/include/mysql -c common.c -o
> common.o
> gcc -g -Wall -Werror -I- -I. -I/usr/local/include/mysql -c client4.c -o
> client4.o
> cc1: warnings being treated as errors
> client4.c: In function `main':
> client4.c:35: warning: passing arg 2 of `load_defaults' from incompatible
> pointer type
> make: *** [show_argv.o] Error 1
>
> This occurs in the groups argument to load_defaults. Groups is declared as
> char *groups[] = {"client", null};
Try putting "const" in front of "char" and see what happens.
> load_defaults is called in the following manner:
>
> <snip>
> my_init();
> load_defaults ("my", groups, &argc, &argv);
> <snip>
>
> When I remove the -Werror, it makes fine, and the program runs correctly.
> Has anybody else encountered
> this problem?
>
> Software versions:
> glibc version is 2.1.3-15
> mysql version is 3.23.27-beta, installed from source with
> ./configure --enable-thread-safe-client --with-pthread --with-debug
> Running Redhat 6.2 (Zoot)
>
> Thanx
> -Brian K. Hlady
---------------------------------------------------------------------
Before posting, please check:
http://www.mysql.com/manual.php (the manual)
http://lists.mysql.com/ (the list archive)
To request this thread, e-mail <[EMAIL PROTECTED]>
To unsubscribe, e-mail <[EMAIL PROTECTED]>
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php