diff options
author | Richard Jones <rjones@redhat.com> | 2009-04-08 23:47:31 +0100 |
---|---|---|
committer | Richard Jones <rjones@redhat.com> | 2009-04-08 23:47:31 +0100 |
commit | c168ce1c91c8f4f615ec53e140970e0017ad750d (patch) | |
tree | a4d3c6b3cbf4a42f5fa9cf6fdb33ecda27a2bfd6 /perl/lib/Sys | |
parent | f4299f7ea55c4bbc9302e102d2fc801829e75ef6 (diff) | |
download | libguestfs-c168ce1c91c8f4f615ec53e140970e0017ad750d.tar.gz libguestfs-c168ce1c91c8f4f615ec53e140970e0017ad750d.tar.xz libguestfs-c168ce1c91c8f4f615ec53e140970e0017ad750d.zip |
Generated code for new guestfs_read_lines API call.
Diffstat (limited to 'perl/lib/Sys')
-rw-r--r-- | perl/lib/Sys/Guestfs.pm | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/perl/lib/Sys/Guestfs.pm b/perl/lib/Sys/Guestfs.pm index 1798e7b8..7706ae40 100644 --- a/perl/lib/Sys/Guestfs.pm +++ b/perl/lib/Sys/Guestfs.pm @@ -244,6 +244,18 @@ See also C<$h-E<gt>pvs_full>. List all the physical volumes detected. This is the equivalent of the L<pvs(8)> command. The "full" version includes all fields. +=item @lines = $h->read_lines (path); + +Return the contents of the file named C<path>. + +The file contents are returned as a list of lines. Trailing +C<LF> and C<CRLF> character sequences are I<not> returned. + +Note that this function cannot correctly handle binary files +(specifically, files containing C<\0> character which is treated +as end of line). For those you need to use the C<$h-E<gt>read_file> +function which has a more complex interface. + =item $h->set_autosync (autosync); If C<autosync> is true, this enables autosync. Libguestfs will make a |