On Sat, Oct 24, 2015 at 12:59:14PM +0300, Maxim Perevedentsev wrote:
 +int64_t
 +xfs_minimum_size (const char *path)
 +{
 +  CLEANUP_FREE guestfs_int_xfsinfo *info = do_xfs_info (path);
 +
 +  if (info == NULL)
 +    return -1;
 +
 +  // XFS does not support shrinking.
 +  return info->xfs_blocksize * info->xfs_datablocks;
 +} 
My spidey sense says .. what happens if this multiplication overflows?
Maybe nothing bad.  Nevertheless, both of these numbers are under
end-user control.
Rest of the patch looks fine to me.
Rich.
-- 
Richard Jones, Virtualization Group, Red Hat 
http://people.redhat.com/~rjones
Read my programming and virtualization blog: 
http://rwmj.wordpress.com
Fedora Windows cross-compiler. Compile Windows programs, test, and
build Windows installers. Over 100 libraries supported.
http://fedoraproject.org/wiki/MinGW