search for: 1f129a7

Displaying 6 results from an estimated 6 matches for "1f129a7".

2016 Jul 18
2
[PATCH] mllib: Getopt: fix integer parsing
...se of xstrtol to parse the integer arguments to avoid extra suffixes, etc. Fixes commit 0f7bf8f714898c606e5d5015fff5b7803dcd1aee. --- mllib/getopt-c.c | 34 ++++++++++++++++++++++++---------- 1 file changed, 24 insertions(+), 10 deletions(-) diff --git a/mllib/getopt-c.c b/mllib/getopt-c.c index 1f129a7..2d3f9b6 100644 --- a/mllib/getopt-c.c +++ b/mllib/getopt-c.c @@ -30,6 +30,8 @@ #include <error.h> #include <assert.h> +#include "xstrtol.h" + #include <caml/alloc.h> #include <caml/fail.h> #include <caml/memory.h> @@ -117,6 +119,26 @@ do_call1 (value...
2016 Jul 15
0
[PATCH 1/3] mllib: Fix parsing of integers on the command line and use correct int type.
...type is 31 or 63 bits. Probably we should have explicit 'int32' and 'int64' types in the OCaml code, instead of using (native) 'int'. --- mllib/getopt-c.c | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/mllib/getopt-c.c b/mllib/getopt-c.c index 1f129a7..afb8793 100644 --- a/mllib/getopt-c.c +++ b/mllib/getopt-c.c @@ -247,7 +247,8 @@ guestfs_int_mllib_getopt_parse (value argsv, value specsv, value anon_funv, valu actionv = Field (specv, 1); switch (Tag_val (actionv)) { - int num; + long num; + int nchars; case 0: /* Un...
2016 Jul 18
0
Re: [PATCH] mllib: Getopt: fix integer parsing
...ents to avoid extra suffixes, etc. > > Fixes commit 0f7bf8f714898c606e5d5015fff5b7803dcd1aee. > --- > mllib/getopt-c.c | 34 ++++++++++++++++++++++++---------- > 1 file changed, 24 insertions(+), 10 deletions(-) > > diff --git a/mllib/getopt-c.c b/mllib/getopt-c.c > index 1f129a7..2d3f9b6 100644 > --- a/mllib/getopt-c.c > +++ b/mllib/getopt-c.c > @@ -30,6 +30,8 @@ > #include <error.h> > #include <assert.h> > > +#include "xstrtol.h" > + > #include <caml/alloc.h> > #include <caml/fail.h> > #include <...
2016 Jul 18
2
Re: [PATCH] mllib: Getopt: fix integer parsing
...> > > Fixes commit 0f7bf8f714898c606e5d5015fff5b7803dcd1aee. > > --- > > mllib/getopt-c.c | 34 ++++++++++++++++++++++++---------- > > 1 file changed, 24 insertions(+), 10 deletions(-) > > > > diff --git a/mllib/getopt-c.c b/mllib/getopt-c.c > > index 1f129a7..2d3f9b6 100644 > > --- a/mllib/getopt-c.c > > +++ b/mllib/getopt-c.c > > @@ -30,6 +30,8 @@ > > #include <error.h> > > #include <assert.h> > > > > +#include "xstrtol.h" > > + > > #include <caml/alloc.h> > >...
2016 Jul 15
5
[PATCH 0/3] mllib: Various fixes and changes to Getopt module.
The second patch is obviously not complete yet - for discussion only. Rich.
2016 Jul 13
3
[PATCH v3 1/2] OCaml tools: add and use a Getopt module
...hem, and setting [long_options] to them. - Returns the resulting options. *) + Returns a new [Getopt.t] handle. *) val compare_version : string -> string -> int (** Compare two version strings. *) diff --git a/mllib/getopt-c.c b/mllib/getopt-c.c new file mode 100644 index 0000000..1f129a7 --- /dev/null +++ b/mllib/getopt-c.c @@ -0,0 +1,316 @@ +/* argument parsing using getopt(3) + * Copyright (C) 2016 Red Hat Inc. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software...