On 15.11.18 19:02, Eric Blake wrote:
> If the conversion underflows, store ±0.0 in @result, depending on the
> sign, and return -ERANGE.
Will do! Thanks!
--
Thanks,
David / dhildenb
On 11/15/18 11:25 AM, David Hildenbrand wrote:
Also, just overflow. Floating-point underflow is when a computation's
mathematical result is too close to zero to be represented without
extraordinary rounding error.
works like qemu_strtoul(). I'd prefer longhand for qemu_strtod(). It
costs
On 15.11.18 17:22, Markus Armbruster wrote:
> Eric Blake writes:
>
>> On 11/15/18 8:04 AM, David Hildenbrand wrote:
>>> Let's provide a wrapper for strtod().
>>>
>>> Signed-off-by: David Hildenbrand
>>> ---
>>> include/qemu/cutils.h | 2 ++
>>> util/cutils.c | 38
Eric Blake writes:
> On 11/15/18 8:04 AM, David Hildenbrand wrote:
>> Let's provide a wrapper for strtod().
>>
>> Signed-off-by: David Hildenbrand
>> ---
>> include/qemu/cutils.h | 2 ++
>> util/cutils.c | 38 ++
>> 2 files changed, 40 insertions(
On 11/15/18 8:04 AM, David Hildenbrand wrote:
Let's provide a wrapper for strtod().
Signed-off-by: David Hildenbrand
---
include/qemu/cutils.h | 2 ++
util/cutils.c | 38 ++
2 files changed, 40 insertions(+)
+
+/**
+ * Convert string @nptr t
Let's provide a wrapper for strtod().
Signed-off-by: David Hildenbrand
---
include/qemu/cutils.h | 2 ++
util/cutils.c | 38 ++
2 files changed, 40 insertions(+)
diff --git a/include/qemu/cutils.h b/include/qemu/cutils.h
index 7071bfe2d4..756b41c193