Fix error handling in qemu_read_config_file
authorKevin Wolf <kwolf@redhat.com>
Mon, 17 May 2010 08:36:47 +0000 (10:36 +0200)
committerAnthony Liguori <aliguori@us.ibm.com>
Mon, 24 May 2010 20:18:23 +0000 (15:18 -0500)
commitd28d1eb8fbdc959250464b56ac853f43ac779592
treea94af7efd41021bd43b7c581fcaedca1e19ad51c
parentd5ac5dda1988336cead6adeb24f51fe711fa1730
Fix error handling in qemu_read_config_file

We need to close the file even in error case. While at it, make the callers
catch all kind of errors. ENOENT is allowed for default config files, they
are optional.

Reported-by: Luiz Capitulino <lcapitulino@redhat.com>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
qemu-config.c
vl.c