Displaying 5 results from an estimated 5 matches for "pylong".
Did you mean:
pylon
2020 Aug 10
2
[PATCH nbdkit] python: Allow extents to return any iterable (which includes lists).
...st of 3-tuples");
+ nbdkit_error ("extents method did not return an iterable of 3-tuples");
+ Py_DECREF (iter);
Py_DECREF (r);
return -1;
}
@@ -1078,16 +1075,26 @@ py_extents (void *handle, uint32_t count, uint64_t offset,
extent_length = PyLong_AsUnsignedLongLong (py_length);
extent_type = PyLong_AsUnsignedLong (py_type);
if (check_python_failure ("PyLong") == -1) {
+ Py_DECREF (iter);
Py_DECREF (r);
return -1;
}
if (nbdkit_add_extent (extents,
ex...
2020 Aug 10
5
[PATCH nbdkit] python: Implement can_extents + extents.
...t) != 3) {
+ nbdkit_error ("extents method did not return a list of 3-tuples");
+ Py_DECREF (r);
+ return -1;
+ }
+ py_offset = PyTuple_GetItem (t, 0);
+ py_length = PyTuple_GetItem (t, 1);
+ py_type = PyTuple_GetItem (t, 2);
+ extent_offset = PyLong_AsUnsignedLongLong (py_offset);
+ extent_length = PyLong_AsUnsignedLongLong (py_length);
+ extent_type = PyLong_AsUnsignedLong (py_type);
+ if (check_python_failure ("PyLong") == -1) {
+ Py_DECREF (r);
+ return -1;
+ }
+ if (nbdkit_add_extent (extent...
2019 Aug 11
4
[PATCH libnbd v2 0/3] python: Add test for doing asynch copy.
v1 was here:
https://www.redhat.com/archives/libguestfs/2019-August/msg00103.html
In v2 I've made several changes:
- Fix Python callbacks so if they don't return something
which is int-like, we assume they mean to return 0.
- Add nbd.Buffer free() method. Read commit message in
patch 2 to see what this is about.
- Fixed the asynch copy test to deal with the unbelievably
2020 Aug 10
0
Re: [PATCH nbdkit] python: Implement can_extents + extents.
...quot;extents method did not return a list of 3-tuples");
> + Py_DECREF (r);
> + return -1;
> + }
> + py_offset = PyTuple_GetItem (t, 0);
> + py_length = PyTuple_GetItem (t, 1);
> + py_type = PyTuple_GetItem (t, 2);
> + extent_offset = PyLong_AsUnsignedLongLong (py_offset);
> + extent_length = PyLong_AsUnsignedLongLong (py_length);
> + extent_type = PyLong_AsUnsignedLong (py_type);
> + if (check_python_failure ("PyLong") == -1) {
Is it really right to be doing error checking only once, but after three...
2020 Aug 10
0
Re: [PATCH nbdkit] python: Implement can_extents + extents.
...quot;extents method did not return a list of 3-tuples");
> + Py_DECREF (r);
> + return -1;
> + }
> + py_offset = PyTuple_GetItem (t, 0);
> + py_length = PyTuple_GetItem (t, 1);
> + py_type = PyTuple_GetItem (t, 2);
> + extent_offset = PyLong_AsUnsignedLongLong (py_offset);
> + extent_length = PyLong_AsUnsignedLongLong (py_length);
> + extent_type = PyLong_AsUnsignedLong (py_type);
> + if (check_python_failure ("PyLong") == -1) {
> + Py_DECREF (r);
> + return -1;
> + }
> +...