mirror of
https://github.com/libguestfs/libguestfs.git
synced 2026-03-21 22:53:37 +00:00
fish: Use size_t instead of int for iteration over an array
Signed-off-by: Susant Sahani <ssahani@redhat.com>
This commit is contained in:
@@ -73,11 +73,10 @@ run_copy_out (const char *cmd, size_t argc, char *argv[])
|
||||
|
||||
/* Local directory is always the last arg. */
|
||||
const char *local = argv[argc-1];
|
||||
const int nr_remotes = argc-1;
|
||||
const size_t nr_remotes = argc-1;
|
||||
|
||||
/* Download each remote one at a time using copy-out. */
|
||||
int i, r;
|
||||
for (i = 0; i < nr_remotes; ++i) {
|
||||
for (size_t i = 0; i < nr_remotes; ++i) {
|
||||
CLEANUP_FREE char *remote = NULL;
|
||||
|
||||
/* Allow win:... prefix on remotes. */
|
||||
@@ -85,7 +84,7 @@ run_copy_out (const char *cmd, size_t argc, char *argv[])
|
||||
if (remote == NULL)
|
||||
return -1;
|
||||
|
||||
r = guestfs_copy_out (g, remote, local);
|
||||
size_t r = guestfs_copy_out (g, remote, local);
|
||||
if (r == -1)
|
||||
return -1;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user