resize: Don't truncate libguestfs error messages.

If we rely on OCaml's internal exception printing, then it will
truncate error messages like this:

  Fatal error: exception Guestfs.Error("could not create appliance
  through libvirt.

  Try running qemu directly without libvirt using this environment
  variable: export LIBGUESTFS_BACKEND=direct

  Original error from libvirt: unable to set security context
  'unconfined_u:object_r:svi
note the truncation here ^^^^^^^

Instead of using the internal exception printing, wrap the whole
program in a 'main ()' function and add an exception handler.

This large change is non-functional apart from the addition of the
exception handlers at the end.
This commit is contained in:
Richard W.M. Jones
2014-01-23 14:14:26 +00:00
parent e8c1067021
commit 3331db84bc

File diff suppressed because it is too large Load Diff