|
From: Steve D. <ste...@us...> - 2009-01-23 00:13:29
|
Update of /cvsroot/evms/evms2/engine/tests In directory 23jxhf1.ch3.sourceforge.com:/tmp/cvs-serv24869 Modified Files: evms_clean.c evms_deactivate.c lvm2_crc.c seq_dd.c Log Message: Cleanup compiler warnings. Index: seq_dd.c =================================================================== RCS file: /cvsroot/evms/evms2/engine/tests/seq_dd.c,v retrieving revision 1.3 retrieving revision 1.4 diff -u -d -r1.3 -r1.4 --- seq_dd.c 6 Apr 2004 20:28:09 -0000 1.3 +++ seq_dd.c 23 Jan 2009 00:13:22 -0000 1.4 @@ -48,7 +48,8 @@ { u_int64_t *buffer; unsigned long i; - int fd, rc, j, failed = 0; + int fd, rc; + uint j, failed = 0; buffer = malloc(SECTOR_SIZE); if (!buffer) { @@ -100,7 +101,8 @@ { u_int64_t *buffer; unsigned long i; - int fd, rc, j; + int fd, rc; + uint j; buffer = malloc(SECTOR_SIZE); if (!buffer) { Index: lvm2_crc.c =================================================================== RCS file: /cvsroot/evms/evms2/engine/tests/lvm2_crc.c,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- lvm2_crc.c 10 Oct 2005 15:56:03 -0000 1.1 +++ lvm2_crc.c 23 Jan 2009 00:13:22 -0000 1.2 @@ -41,7 +41,8 @@ { void *buffer; char *filename; - u_int32_t crc, size; + u_int32_t crc; + ssize_t size; u_int64_t offset; int fd; @@ -68,7 +69,7 @@ return 3; } - if (lseek64(fd, offset, SEEK_SET) != offset) { + if (lseek64(fd, offset, SEEK_SET) != (off64_t) offset) { printf("Error: Could not seek to offset %lu in %s.\n", (unsigned long)offset, filename); return 4; Index: evms_clean.c =================================================================== RCS file: /cvsroot/evms/evms2/engine/tests/evms_clean.c,v retrieving revision 1.11 retrieving revision 1.12 diff -u -d -r1.11 -r1.12 --- evms_clean.c 15 Jan 2009 00:42:42 -0000 1.11 +++ evms_clean.c 23 Jan 2009 00:13:22 -0000 1.12 @@ -301,7 +301,7 @@ static int delete_parent_objects(handle_object_info_t * obj_info) { int rc = 0; - int i; + uint i; for (i = 0; i < obj_info->info.disk.parent_objects->count; i++) { @@ -347,7 +347,7 @@ static int clean_parent_objects(handle_object_info_t * obj_info) { int rc = 0; - int i; + uint i; for (i = 0; i < obj_info->info.disk.parent_objects->count; i++) { @@ -451,7 +451,7 @@ static int clean_container(handle_object_info_t * con_info) { int rc = 0; - int i; + uint i; for (i = 0; i < con_info->info.container.objects_produced->count; i++) { @@ -715,4 +715,3 @@ return rc; } - Index: evms_deactivate.c =================================================================== RCS file: /cvsroot/evms/evms2/engine/tests/evms_deactivate.c,v retrieving revision 1.4 retrieving revision 1.5 diff -u -d -r1.4 -r1.5 --- evms_deactivate.c 25 Sep 2003 14:54:26 -0000 1.4 +++ evms_deactivate.c 23 Jan 2009 00:13:22 -0000 1.5 @@ -311,7 +311,7 @@ * * Open the DM control node, issue the REMOVE_ALL ioctl, and close. **/ -int main(int argc, char **argv) +int main() { dm_ioctl_t dmi; int rc; @@ -330,7 +330,7 @@ rc = ioctl(dm_control_fd, DM_REMOVE_ALL, &dmi); if (rc) { rc = errno; - fprintf(stderr, "ioctl failed with error code %d: %s\n", + fprintf(stderr, "ioctl failed with error code %d: %s\n", rc, strerror(rc)); goto out; } |