search for: sviv

Displaying 12 results from an estimated 12 matches for "sviv".

Did you mean: sdiv
2016 May 06
1
[PATCH] perl: use INT2PTR macro for casting back to guestfs_h * (RHBZ#1150298)
...rator/perl.ml b/generator/perl.ml index 19cabb6..a665051 100644 --- a/generator/perl.ml +++ b/generator/perl.ml @@ -242,7 +242,7 @@ DESTROY (sv) HV *hv = (HV *) SvRV (sv); SV **svp = hv_fetch (hv, \"_g\", 2, 0); if (svp != NULL) { - guestfs_h *g = (guestfs_h *) SvIV (*svp); + guestfs_h *g = INT2PTR (guestfs_h *, SvIV (*svp)); _close_handle (g); } diff --git a/perl/typemap b/perl/typemap index 508e378..0a92e53 100644 --- a/perl/typemap +++ b/perl/typemap @@ -14,7 +14,7 @@ O_OBJECT_guestfs_h SV **svp = hv_fetch (hv, \"_g\&q...
2011 Jun 28
2
minor Hivex.xs leaks
...ototype to pass -Wmissing-prototypes */ XS(XS_Win__Hivex_node_set_values) { #ifdef dVAR dVAR; dXSARGS; #else dXSARGS; #endif if (items != 3) croak_xs_usage(cv, "h, node, values"); PERL_UNUSED_VAR(ax); /* -Wall */ SP -= items; { hive_h * h; int node = (int)SvIV(ST(1)); pl_set_values values = unpack_pl_set_values (ST(2)); #line 477 "Hivex.xs" int r; #line 993 "Hivex.c" if (sv_isobject (ST(0)) && SvTYPE (SvRV (ST(0))) == SVt_PVMG) h = (hive_h *) SvIV ((SV *) SvRV (ST(0))); else { warn ("Win::H...
2017 Jan 31
4
[nbdkit PATCH v3 0/3] bind .zero to Perl
Requires patch 1 and 2 of the python series: https://www.redhat.com/archives/libguestfs/2017-January/msg00126.html This is the perl implementation along the same lines. We still haven't decided if patch 1 of the python series should change OCaml to report errno as reliable or not, but perhaps we can commit that patch as-is now and then touch things up further when we actually get set_error
2011 Mar 11
2
int to string TypeError annoyance
Hi All, In Perl, $db->set_metadata( "foo", 10 ); Results in, TypeError in method 'WritableDatabase_set_metadata', argument 3 of type 'std::string const &' It looks like this is thrown by the SWIG std::string typemap. Does someone with better SWIG skills than me know how to fix SWIG such that it converts the int to a string rather than croaking? (And
2010 Jul 07
1
[PATCH] hivex: add hivex_set_value api call and ocaml/perl bindings, tests
...= hv_fetch (hv, \"key\", 3, 0); + if (!svp || !*svp) + croak (\"missing 'key' in hash\"); + ret->key = SvPV_nolen (*svp); + + svp = hv_fetch (hv, \"t\", 1, 0); + if (!svp || !*svp) + croak (\"missing 't' in hash\"); + ret->t = SvIV (*svp); + + svp = hv_fetch (hv, \"value\", 5, 0); + if (!svp || !*svp) + croak (\"missing 'value' in hash\"); + ret->value = SvPV (*svp, ret->len); + + return ret; +} + MODULE = Win::Hivex PACKAGE = Win::Hivex PROTOTYPES: ENABLE @@ -2319,6 +2388,8 @@ DE...
2010 Jul 03
1
[PATCH] hivex: add hivex_set_value api call and perl bindings, tests
...= hv_fetch (hv, \"key\", 3, 0); + if (!svp || !*svp) + croak (\"missing 'key' in hash\"); + ret->key = SvPV_nolen (*svp); + + svp = hv_fetch (hv, \"t\", 1, 0); + if (!svp || !*svp) + croak (\"missing 't' in hash\"); + ret->t = SvIV (*svp); + + svp = hv_fetch (hv, \"value\", 5, 0); + if (!svp || !*svp) + croak (\"missing 'value' in hash\"); + ret->value = SvPV (*svp, ret->len); + + return ret; +} + MODULE = Win::Hivex PACKAGE = Win::Hivex PROTOTYPES: ENABLE @@ -2319,6 +2371,8 @@ DE...
2017 Jan 24
4
[nbdkit PATCH 0/2] bind .zero to more languages
Begin the language binding followups to my new .zero callback, since Rich was indeed correct that we want them. I'm more familiar with python and perl (at least to the point that I was able to modify the appropriate example files and prove to myself that the bindings worked), so I've started with those. I'm less familiar with ruby and ocaml, so I've left those for tomorrow (it
2017 Jan 31
3
[nbdkit PATCH 0/2] fix pod and other errors in recent patches
POD errors are not nice, and 'pod2man --stderr' does not do what we want. Eric Blake (2): perl: Fix previous patches build: Kill build on POD error .gitignore | 2 ++ configure.ac | 10 +--------- docs/Makefile.am | 8 ++++++-- docs/nbdkit-plugin.pod | 2 +- plugins/curl/Makefile.am | 4 +++-
2012 Jan 09
1
[PATCH 1/2] generator: Rename java_structs to camel_structs to better reflect their purpose
This map was originally included just for the java bindings, but is generally useful to any binding which uses camel case by requirement or convention. --- generator/generator_haskell.ml | 4 ++-- generator/generator_java.ml | 10 +++++----- generator/generator_main.ml | 2 +- generator/generator_structs.ml | 12 +++++------- generator/generator_structs.mli | 8 ++++---- 5
2012 Aug 14
7
[PATCH 0/7] Add tar compress, numericowner, excludes flags.
https://bugzilla.redhat.com/show_bug.cgi?id=847880 https://bugzilla.redhat.com/show_bug.cgi?id=847881 This patch series adds various optional arguments to the tar-in and tar-out commands. Firstly (1/7) an optional "compress" flag is added to select compression. This makes the calls tgz-in/tgz-out/txz-in/txz-out deprecated, and expands the range of compression types available.
2010 Aug 31
13
[PATCH v2] Add progress bars
This is an updated and extended version of the original patch: https://www.redhat.com/archives/libguestfs/2010-August/msg00163.html This adds OCaml and Perl bindings (both tested), support for progress bars in virt-resize, and adds progress notifications to a number of the simpler commands. Still to do is to add progress messages to more commands. There are still a few commands which would be
2009 Aug 03
1
[PATCH 1/2] Convert all TABs-as-indentation to spaces.
...o perl-libintl module"; - exit 0; + plan skip_all => "no perl-libintl module"; + exit 0; } } diff --git a/perl/typemap b/perl/typemap index 421e73a..97788d3 100644 --- a/perl/typemap +++ b/perl/typemap @@ -9,7 +9,7 @@ O_OBJECT_guestfs_h $var = ($type) SvIV ((SV *) SvRV ($arg)); else { warn (\"${Package}::$func_name(): $var is not a blessed SV reference\"); - XSRETURN_UNDEF; + XSRETURN_UNDEF; } OUTPUT diff --git a/recipes/squashfs.example b/recipes/squashfs.example index 9dae930..f10d195 100644 --- a/recipes/squas...