Displaying 6 results from an estimated 6 matches for "unsigned_long".
2019 Sep 23
0
Re: [PATCH nbdkit v2] server: public: Add nbdkit_parse_* functions for safely parsing integers.
...n Linux and BSD, I wouldn't
>> hold my breath on it lasting forever.
>
> I should say our existing code already has this bug, this
> patch doesn't change it :-)
True.
>
> Below is V2 which fixes everything you mentioned. In this version I
> have got rid of long, unsigned_long, size_t and ssize_t, but added
> int8_t and uint8_t.
>
Looks reasonable.
> This may change command line parsing in a few corner cases:
>
> * For some parameters you might have written (eg)
> ‘cache-high-threshold=08’ to mean decimal 8, but now it would be a
> parse err...
2010 Aug 18
16
[PATCH 00 of 16] libxl: autogenerate type definitions and destructor functions
The series introduces auto-generation of the type definitions used in
the libxl interface followed by auto-generation of a destructor
function for each type. In the future it may be possible to use the
related data structures for other purposes, for example auto-generation
of the functions to marshal between C and language binding data types.
tools/_libxl_types.h should be identical both before
2019 Sep 21
2
[PATCH nbdkit] server: public: Add nbdkit_parse_* functions for safely parsing integers.
...;, L<atoi(3)> and
+similar.
+
+ int nbdkit_parse_int (const char *what, const char *str, int *r);
+ int nbdkit_parse_unsigned (const char *what,
+ const char *str, unsigned *r);
+ int nbdkit_parse_long (const char *what, const char *str, long *r);
+ int nbdkit_parse_unsigned_long (const char *what,
+ const char *str, unsigned long *r);
+ int nbdkit_parse_int16_t (const char *what,
+ const char *str, int16_t *r);
+ int nbdkit_parse_uint16_t (const char *what,
+ const char *str, uint16_t *r);...
2010 Sep 09
2
[PATCH]: add libxl python binding
...e_t = Builtin("size_t", namespace = None)
+size_t = Number("size_t", namespace = None)
-integer = Builtin("int", namespace = None)
-unsigned_integer = Builtin("unsigned int", namespace = None)
-unsigned = Builtin("unsigned int", namespace = None)
-unsigned_long = Builtin("unsigned long", namespace = None)
+integer = Number("int", namespace = None, signed = True)
+unsigned_integer = Number("unsigned int", namespace = None)
+unsigned = Number("unsigned int", namespace = None)
+unsigned_long = Number("unsigned lon...
2019 Sep 23
2
[PATCH nbdkit v2] server: public: Add nbdkit_parse_* functions for safely parsing integers.
...o while your assumption may hold for now on Linux and BSD, I wouldn't
> hold my breath on it lasting forever.
I should say our existing code already has this bug, this
patch doesn't change it :-)
Below is V2 which fixes everything you mentioned. In this version I
have got rid of long, unsigned_long, size_t and ssize_t, but added
int8_t and uint8_t.
Rich.
>From 375e286be27f563a9f1a886e29bdcfcebebfa81c Mon Sep 17 00:00:00 2001
From: "Richard W.M. Jones" <rjones@redhat.com>
Date: Sat, 21 Sep 2019 07:30:40 +0100
Subject: [PATCH] server: public: Add nbdkit_parse_* functions fo...
2019 Sep 23
2
Re: [PATCH nbdkit] server: public: Add nbdkit_parse_* functions for safely parsing integers.
On Mon, Sep 23, 2019 at 12:05:11PM -0500, Eric Blake wrote:
> > + int nbdkit_parse_long (const char *what, const char *str, long *r);
> > + int nbdkit_parse_unsigned_long (const char *what,
> > + const char *str, unsigned long *r);
>
> Do we really want to encourage the use of parse_long and
> parse_unsigned_long? Those differ between 32- and 64-bit platforms, at
> which point, it's often better to explicitly c...