summaryrefslogtreecommitdiffstats
path: root/perl
diff options
context:
space:
mode:
authorRichard Jones <rjones@redhat.com>2009-06-08 17:44:18 +0100
committerRichard Jones <rjones@redhat.com>2009-06-08 17:44:18 +0100
commit460d139e6a52da67a4f1947035b1978610349f78 (patch)
tree798177aa71bc9615074cd1a9a351ff4b38165c7c /perl
parent3de234656bc61a2d35b0f1a9ccb1e6ef7535166b (diff)
downloadlibguestfs-460d139e6a52da67a4f1947035b1978610349f78.tar.gz
libguestfs-460d139e6a52da67a4f1947035b1978610349f78.tar.xz
libguestfs-460d139e6a52da67a4f1947035b1978610349f78.zip
Generated code for ntfs_3g_probe command.
Diffstat (limited to 'perl')
-rw-r--r--perl/Guestfs.xs15
-rw-r--r--perl/lib/Sys/Guestfs.pm14
2 files changed, 29 insertions, 0 deletions
diff --git a/perl/Guestfs.xs b/perl/Guestfs.xs
index 7b923f6a..c26faa16 100644
--- a/perl/Guestfs.xs
+++ b/perl/Guestfs.xs
@@ -2534,3 +2534,18 @@ PREINIT:
if (r == -1)
croak ("sleep: %s", guestfs_last_error (g));
+SV *
+ntfs_3g_probe (g, rw, device)
+ guestfs_h *g;
+ int rw;
+ char *device;
+PREINIT:
+ int status;
+ CODE:
+ status = guestfs_ntfs_3g_probe (g, rw, device);
+ if (status == -1)
+ croak ("ntfs_3g_probe: %s", guestfs_last_error (g));
+ RETVAL = newSViv (status);
+ OUTPUT:
+ RETVAL
+
diff --git a/perl/lib/Sys/Guestfs.pm b/perl/lib/Sys/Guestfs.pm
index 445d9b8b..05adfcb4 100644
--- a/perl/lib/Sys/Guestfs.pm
+++ b/perl/lib/Sys/Guestfs.pm
@@ -889,6 +889,20 @@ Some internal mounts are not shown.
This moves a file from C<src> to C<dest> where C<dest> is
either a destination filename or destination directory.
+=item $status = $h->ntfs_3g_probe ($rw, $device);
+
+This command runs the L<ntfs-3g.probe(8)> command which probes
+an NTFS C<device> for mountability. (Not all NTFS volumes can
+be mounted read-write, and some cannot be mounted at all).
+
+C<rw> is a boolean flag. Set it to true if you want to test
+if the volume can be mounted read-write. Set it to false if
+you want to test if the volume can be mounted read-only.
+
+The return value is an integer which C<0> if the operation
+would succeed, or some non-zero value documented in the
+L<ntfs-3g.probe(8)> manual page.
+
=item $h->ping_daemon ();
This is a test probe into the guestfs daemon running inside