pointer targets in passing argument 2 of ‘strcpy’ differ in signedness

lano

Aktives Mitglied
Moin.

Ich bekomm von gcc ne Warunung und hab nicht so recht ne Idee was ich daraus machen soll.

Angezeigt wird mir die Stelle:
C:
if (strcmp(conf.Type,"") == 0) strcpy(conf.Type, sqlite3_column_text(res, 1) );

sqlite2_columm_text:
const unsigned char *sqlite3_column_text(sqlite3_stmt*, int iCol);

komm ich da um memcpy nicht drum rum ?
Eigentlich ists doch auch egal oder?
 
gcc -Wall -O3 main.c juisck3.c juisdb.c juisnet.c -o bin/juisck3-`uname -m` -lsqlite3

Code:
juisdb.c:509:80: note: expected ‘const char *’ but argument is of type ‘const unsigned char *’
juisdb.c:510:80: warning: pointer targets in passing argument 2 of ‘strcpy’ differ in signedness [-Wpointer-sign]
         if (strcmp(conf.fb_name,"") == 0)         strcpy(conf.fb_name,         sqlite3_column_text(res, 2) );
                                                                                ^~~~~~~~~~~~~~~~~~~
In file included from juisdb.h:10:0,
                 from juisdb.c:2:

Code:
gcc (Raspbian 6.3.0-18+rpi1+deb9u1) 6.3.0 20170516
Copyright (C) 2016 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
 
Zurück
Oben Unten