All of lore.kernel.org
 help / color / mirror / Atom feed
From: Paolo Bonzini <pbonzini@redhat.com>
To: "Andreas Färber" <afaerber@suse.de>, qemu-devel@nongnu.org
Cc: Markus Armbruster <armbru@redhat.com>,
	Bruce Rogers <brogers@suse.com>,
	Michael Roth <mdroth@linux.vnet.ibm.com>, Lin Ma <lma@suse.com>
Subject: Re: [Qemu-devel] [PATCH 6/7] cutils: Normalize qemu_strto[u]ll() signature
Date: Fri, 25 Sep 2015 15:47:07 +0200	[thread overview]
Message-ID: <5605505B.4090507@redhat.com> (raw)
In-Reply-To: <56054BA4.7040200@suse.de>



On 25/09/2015 15:27, Andreas Färber wrote:
>> > 
>> > No, I really mean the types. :) The qemu_strtoll/qemu_strtoull functions
>> > use {,u}int64_t because they are much more used than long long and
>> > unsigned long long.
> Well, my answer still stands: The next patch has code using long long.
> 
> Problem is that uint64_t foo = strtoull(...) works, while
> qemu_strtoull(..., &foo) causes a pointer mismatch warning treated as
> error. I could've converted those to uint64_t (assuming the type is not
> needed for something else), but I rather wanted to keep changes small.
> 
> If we want functions using [u]int64_t, we should name them
> ...strto[u]64, not mixing C and POSIX types.

Good point.  Yes, I would prefer the function to be renamed and using
uint64_t in string-input-visitor.

Paolo

> But I assumed there may be some controversy, so I intentionally put this
> after the actual bug fixes and test cases, they can easily be dropped. :)

  reply	other threads:[~2015-09-25 13:47 UTC|newest]

Thread overview: 25+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-09-25 12:39 [Qemu-devel] [PATCH 0/7] visitor: Fix uint64 parsing for scsi-disk wwn Andreas Färber
2015-09-25 12:39 ` [Qemu-devel] [PATCH 1/7] string-input-visitor: Fix uint64 parsing Andreas Färber
2015-09-25 14:49   ` Eric Blake
2015-11-11 19:26     ` Andreas Färber
2015-09-30 13:19   ` Markus Armbruster
2015-09-30 13:23     ` Andreas Färber
2015-09-30 13:48       ` Eric Blake
2015-09-30 13:47     ` Eric Blake
2015-09-25 12:39 ` [Qemu-devel] [PATCH 2/7] test-string-input-visitor: Add int test case Andreas Färber
2015-09-25 14:50   ` Eric Blake
2015-09-25 12:39 ` [Qemu-devel] [PATCH 3/7] test-string-input-visitor: Add uint64 test Andreas Färber
2015-09-25 14:55   ` Eric Blake
2015-09-25 12:39 ` [Qemu-devel] [PATCH 4/7] tests: Add QOM property unit tests Andreas Färber
2015-09-25 14:58   ` Eric Blake
2015-09-25 15:01   ` Daniel P. Berrange
2015-11-11 19:52     ` Andreas Färber
2015-09-25 12:39 ` [Qemu-devel] [PATCH 5/7] tests: Add scsi-disk test Andreas Färber
2015-09-25 12:39 ` [Qemu-devel] [PATCH 6/7] cutils: Normalize qemu_strto[u]ll() signature Andreas Färber
2015-09-25 12:42   ` Paolo Bonzini
2015-09-25 12:44     ` Andreas Färber
2015-09-25 12:56       ` Paolo Bonzini
2015-09-25 13:27         ` Andreas Färber
2015-09-25 13:47           ` Paolo Bonzini [this message]
2015-09-25 14:59   ` Eric Blake
2015-09-25 12:39 ` [Qemu-devel] [PATCH 7/7] string-input-visitor: Use qemu_strto[u]ll() Andreas Färber

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=5605505B.4090507@redhat.com \
    --to=pbonzini@redhat.com \
    --cc=afaerber@suse.de \
    --cc=armbru@redhat.com \
    --cc=brogers@suse.com \
    --cc=lma@suse.com \
    --cc=mdroth@linux.vnet.ibm.com \
    --cc=qemu-devel@nongnu.org \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.