I'm using Mandrake 9.1 $ gcc --version gcc (GCC) 3.2.2 (Mandrake Linux 9.1 3.2.2-3mdk) I got a strange compilation problem, I just want to communicate it with you. I also attach the diff/patch i use to fix the problem. mjobin:~/KDE/samba/source$ cat output_compil tdb/tdbback.c: In function `add_suffix': tdb/tdbback.c:60: `__ERROR__XX__NEVER_USE_STRCAT___' undeclared (first use in this function) tdb/tdbback.c:60: (Each undeclared identifier is reported only once tdb/tdbback.c:60: for each function it appears in.) tdb/tdbback.c:60: parse error before ';' token make: *** [tdb/tdbback.o] Error 1 Command exited with non-zero status 2 2.02user 0.09system 0:04.28elapsed 49%CPU (0avgtext+0avgdata 0maxresident)k 0inputs+0outputs (2609major+4026minor)pagefaults 0swaps mjobin:~/KDE/samba/source$ mjobin:~/KDE/samba/source$ cvs diff ? output.diff ? output_compil Index: tdb/tdbback.c =================================================================== RCS file: /cvsroot/samba/source/tdb/tdbback.c,v retrieving revision 1.1.2.2 diff -u -3 -p -r1.1.2.2 tdbback.c --- tdb/tdbback.c 2 Oct 2003 18:22:51 -0000 1.1.2.2 +++ tdb/tdbback.c 4 Oct 2003 03:50:39 -0000 @@ -46,6 +46,7 @@ static int failed; + char *add_suffix(const char *name, const char *suffix) { char *ret; @@ -55,8 +56,14 @@ char *add_suffix(const char *name, const fprintf(stderr,"Out of memory!\n"); exit(1); } - strncpy(ret, name, len); - strncat(ret, suffix, len); + //strncpy(ret, name, len); + //strncat(ret, suffix, len); + //strcat not suggested by my compiler ?... + int i, j; + for (i = 0, j = 0; i < strlen(name); i++, j++) + ret[i] = name[i]; + for (i = 0; i < strlen(suffix); i++, j++) + ret[j] = suffix[i]; return ret; } mjobin:~/KDE/samba/source$
not an issue in the previous cvs. Someone must have fixed this and not marked the bug as fixed.
sorry for the same, cleaning up the database to prevent unecessary reopens of bugs.