git.annexia.org
/
libguestfs.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
f48cd1f
)
inspection: Ignore floppy disks and CD-ROM drives (RHBZ#642929).
author
Richard W.M. Jones
<rjones@redhat.com>
Tue, 26 Oct 2010 08:56:55 +0000
(09:56 +0100)
committer
Richard W.M. Jones
<rjones@redhat.com>
Wed, 27 Oct 2010 09:59:45 +0000
(10:59 +0100)
src/inspect.c
patch
|
blob
|
history
diff --git
a/src/inspect.c
b/src/inspect.c
index
3ffb2bd
..
992573a
100644
(file)
--- a/
src/inspect.c
+++ b/
src/inspect.c
@@
-31,6
+31,7
@@
#include <hivex.h>
#include <augeas.h>
#include <hivex.h>
#include <augeas.h>
+#include "c-ctype.h"
#include "ignore-value.h"
#include "xstrtol.h"
#include "ignore-value.h"
#include "xstrtol.h"
@@
-831,6
+832,12
@@
add_fstab_entry (guestfs_h *g, struct inspect_fs *fs,
STREQ (mp, "/sys"))
return 0;
STREQ (mp, "/sys"))
return 0;
+ /* Ignore /dev/fd (floppy disks) (RHBZ#642929) and CD-ROM drives. */
+ if ((STRPREFIX (spec, "/dev/fd") && c_isdigit (spec[7])) ||
+ STREQ (spec, "/dev/floppy") ||
+ STREQ (spec, "/dev/cdrom"))
+ return 0;
+
/* Resolve UUID= and LABEL= to the actual device. */
char *device = NULL;
if (STRPREFIX (spec, "UUID="))
/* Resolve UUID= and LABEL= to the actual device. */
char *device = NULL;
if (STRPREFIX (spec, "UUID="))