qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Peter Xu <peterx@redhat.com>
To: Steve Sistare <steven.sistare@oracle.com>
Cc: qemu-devel@nongnu.org, Juan Quintela <quintela@redhat.com>,
	"Daniel P. Berrange" <berrange@redhat.com>,
	Fabiano Rosas <farosas@suse.de>
Subject: Re: [PATCH V3 2/2] migration: file URI offset
Date: Thu, 29 Jun 2023 17:38:58 -0400	[thread overview]
Message-ID: <ZJ358gdjNdxsZsEa@x1n> (raw)
In-Reply-To: <1687466251-310524-3-git-send-email-steven.sistare@oracle.com>

On Thu, Jun 22, 2023 at 01:37:31PM -0700, Steve Sistare wrote:
> +static int file_parse_offset(char *filespec, uint64_t *offsetp, Error **errp)
> +{
> +    char *option = strstr(filespec, OFFSET_OPTION);
> +    int ret;
> +
> +    if (option) {
> +        *option = 0;
> +        option += sizeof(OFFSET_OPTION) - 1;
> +        ret = qemu_strtosz(option, NULL, offsetp);
> +        if (ret) {
> +            error_setg_errno(errp, ret, "file URI has bad offset %s", option);

Probably "-ret" here.

> +            return -1;
> +        }
> +    }
> +    return 0;
> +}

-- 
Peter Xu



  parent reply	other threads:[~2023-06-29 21:39 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-06-22 20:37 [PATCH V3 0/2] migration file URI Steve Sistare
2023-06-22 20:37 ` [PATCH V3 1/2] migration: " Steve Sistare
2023-06-28 17:07   ` Peter Xu
2023-06-28 17:17     ` Peter Xu
2023-06-22 20:37 ` [PATCH V3 2/2] migration: file URI offset Steve Sistare
2023-06-28 17:26   ` Peter Xu
2023-06-29 21:38   ` Peter Xu [this message]
2023-06-30 14:25     ` Steven Sistare

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=ZJ358gdjNdxsZsEa@x1n \
    --to=peterx@redhat.com \
    --cc=berrange@redhat.com \
    --cc=farosas@suse.de \
    --cc=qemu-devel@nongnu.org \
    --cc=quintela@redhat.com \
    --cc=steven.sistare@oracle.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).