/* guestfish - the filesystem interactive shell
- * Copyright (C) 2009 Red Hat Inc.
+ * Copyright (C) 2009-2010 Red Hat Inc.
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
static void glob_issue (char *cmd, int argc, char ***globs, int *posn, int *count, int *r);
int
-do_glob (const char *cmd, int argc, char *argv[])
+run_glob (const char *cmd, int argc, char *argv[])
{
/* For 'glob cmd foo /s* /usr/s*' this could be:
*
argv[argc] = NULL;
again:
- printf ("%s", argv[0]);
- for (i = 1; i < argc; ++i) {
+ for (i = 1; i < argc; ++i)
argv[i] = globs[i][posn[i]];
- printf (" %s", argv[i]);
- }
- printf ("\n");
if (issue_command (argv[0], &argv[1], NULL) == -1)
*r = -1; /* ... but don't exit */