aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorJason Woodward2005-01-03 03:43:11 +0000
committerJason Woodward2005-01-03 03:43:11 +0000
commit9e0cd138a51d13f0b1ac86191eb2ba999795ecf2 (patch)
treedacfbb5c461ad0c26f504ba2d7616b408d4fd5f2 /src
parent0adb9c8cf235250c8d4d4306878fd6c900ff456a (diff)
downloadslapt-get-9e0cd138a51d13f0b1ac86191eb2ba999795ecf2.tar.gz
added cast to fix strpbrk() void pointer arith warning with gcc-3.4
Diffstat (limited to 'src')
-rw-r--r--src/package.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/package.c b/src/package.c
index c72b485..1bd3770 100644
--- a/src/package.c
+++ b/src/package.c
@@ -296,7 +296,7 @@ struct pkg_list *parse_packages_txt(FILE *pkg_list_fh){
((bytes_read = getline(&getline_buffer,&getline_len,pkg_list_fh)) != EOF) &&
((char_pointer = strstr(getline_buffer,"PACKAGE CONFLICTS")) != NULL)
){
- char *conflicts = strpbrk(char_pointer,":") + 3;
+ char *conflicts = (char *)strpbrk(char_pointer,":") + 3;
if( strlen(conflicts) > CONFLICTS_LEN ){
fprintf( stderr, _("conflict too long [%s:%d]\n"),
conflicts,
@@ -319,7 +319,7 @@ struct pkg_list *parse_packages_txt(FILE *pkg_list_fh){
((bytes_read = getline(&getline_buffer,&getline_len,pkg_list_fh)) != EOF) &&
((char_pointer = strstr(getline_buffer,"PACKAGE SUGGESTS")) != NULL)
){
- char *suggests = strpbrk(char_pointer,":") + 3;
+ char *suggests = (char *)strpbrk(char_pointer,":") + 3;
if( strlen(suggests) > SUGGESTS_LEN ){
fprintf( stderr, _("suggests too long [%s:%d]\n"),
suggests,
@@ -344,7 +344,7 @@ struct pkg_list *parse_packages_txt(FILE *pkg_list_fh){
){
char *md5sum;
getline_buffer[bytes_read - 1] = '\0';
- md5sum = strpbrk(getline_buffer,":") + 3;
+ md5sum = (char *)strpbrk(getline_buffer,":") + 3;
/* don't overflow the buffer */
if( strlen(md5sum) > MD5_STR_LEN ){
fprintf( stderr, _("md5 sum too long [%s %s:%d]\n"),