[libvirt] [PATCH 5/9] Fix error messages in virStorageFileGetMetadataFromFD

Peter Krempa pkrempa at redhat.com
Wed Feb 25 08:49:31 UTC 2015


On Thu, Feb 19, 2015 at 15:59:13 +0100, Ján Tomko wrote:
> Do not use relPath, it has not been filled by virStorageFileMetadataNew.
> ---
>  src/util/virstoragefile.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/src/util/virstoragefile.c b/src/util/virstoragefile.c
> index 8d3d1f5..029fe17 100644
> --- a/src/util/virstoragefile.c
> +++ b/src/util/virstoragefile.c
> @@ -1030,12 +1030,12 @@ virStorageFileGetMetadataFromFD(const char *path,
>      }
>  
>      if (lseek(fd, 0, SEEK_SET) == (off_t)-1) {
> -        virReportSystemError(errno, _("cannot seek to start of '%s'"), meta->relPath);
> +        virReportSystemError(errno, _("cannot seek to start of '%s'"), meta->path);
>          goto cleanup;
>      }
>  
>      if ((len = virFileReadHeaderFD(fd, len, &buf)) < 0) {
> -        virReportSystemError(errno, _("cannot read header '%s'"), meta->relPath);
> +        virReportSystemError(errno, _("cannot read header '%s'"), meta->path);
>          goto cleanup;
>      }

ACK, this is an artifact of the changes done when refactoring to use the
virStorageSource structure everywhere.

Safe for release.

Peter

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: Digital signature
URL: <http://listman.redhat.com/archives/libvir-list/attachments/20150225/94706715/attachment-0001.sig>


More information about the libvir-list mailing list