X-Git-Url: http://git.annexia.org/?p=libguestfs.git;a=blobdiff_plain;f=df%2Fmain.c;h=17aa2830cd61a72b3b43f53dd1917f4990575d55;hp=55e5eaa8c643938478845d7674684aeef352ea1b;hb=607aa95de927b5b8e4b212655c71bf21acbba372;hpb=fdc8805362c6fc587bb7985c5290362ad3094f4e diff --git a/df/main.c b/df/main.c index 55e5eaa..17aa283 100644 --- a/df/main.c +++ b/df/main.c @@ -1,5 +1,5 @@ /* virt-df - * Copyright (C) 2010 Red Hat Inc. + * Copyright (C) 2010-2011 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 @@ -21,10 +21,13 @@ #include #include #include +#include #include #include #include +#include #include +#include #ifdef HAVE_LIBVIRT #include @@ -41,6 +44,7 @@ guestfs_h *g; int read_only = 1; +int live = 0; int verbose = 0; int keys_from_stdin = 0; int echo_keys = 0; @@ -238,6 +242,7 @@ main (int argc, char *argv[]) */ assert (read_only == 1); assert (inspector == 0); + assert (live == 0); /* Must be no extra arguments on the command line. */ if (optind != argc) @@ -281,6 +286,8 @@ main (int argc, char *argv[]) name = strrchr (drvs->a.filename, '/'); if (name == NULL) name = drvs->a.filename; + else + name++; /* skip '/' character */ break; case drv_d: name = drvs->d.guest;