git.annexia.org
/
libguestfs.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
appliance: Document pipe fds.
[libguestfs.git]
/
df
/
main.c
diff --git
a/df/main.c
b/df/main.c
index
9565464
..
cbc6d06
100644
(file)
--- a/
df/main.c
+++ b/
df/main.c
@@
-24,6
+24,7
@@
#include <inttypes.h>
#include <unistd.h>
#include <getopt.h>
#include <inttypes.h>
#include <unistd.h>
#include <getopt.h>
+#include <locale.h>
#include <assert.h>
#ifdef HAVE_LIBVIRT
#include <assert.h>
#ifdef HAVE_LIBVIRT
@@
-279,6
+280,10
@@
main (int argc, char *argv[])
switch (drvs->type) {
case drv_a:
name = strrchr (drvs->a.filename, '/');
switch (drvs->type) {
case drv_a:
name = strrchr (drvs->a.filename, '/');
+ if (name == NULL)
+ name = drvs->a.filename;
+ else
+ name++; /* skip '/' character */
break;
case drv_d:
name = drvs->d.guest;
break;
case drv_d:
name = drvs->d.guest;