From 12cf22ade46ba07aa162a311d3369096292d6d02 Mon Sep 17 00:00:00 2001 From: "Richard W.M. Jones" Date: Fri, 29 Oct 2010 09:46:59 +0100 Subject: [PATCH] inspect: Ignore Pardus "/.swap" swapfile. --- src/inspect.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/src/inspect.c b/src/inspect.c index 5bd332f..3421baa 100644 --- a/src/inspect.c +++ b/src/inspect.c @@ -843,11 +843,12 @@ add_fstab_entry (guestfs_h *g, struct inspect_fs *fs, device = guestfs_findfs_uuid (g, &spec[5]); else if (STRPREFIX (spec, "LABEL=")) device = guestfs_findfs_label (g, &spec[6]); - /* Resolve guest block device names. */ - else if (spec[0] == '/') + /* Ignore "/.swap" (Pardus) and pseudo-devices like "tmpfs". */ + else if (STRPREFIX (spec, "/dev/")) + /* Resolve guest block device names. */ device = resolve_fstab_device (g, spec); - /* Also ignore pseudo-devices completely, like spec == "tmpfs". - * If we haven't resolved the device successfully by this point, + + /* If we haven't resolved the device successfully by this point, * we don't care, just ignore it. */ if (device == NULL) -- 1.8.3.1