Displaying 6 results from an estimated 6 matches for "py_unload".
2020 Sep 01
0
[nbdkit PATCH 1/2] python: Implement .list_exports and friends
...NBDKIT_THREAD_MODEL_PARALLEL
static struct nbdkit_plugin plugin = {
- .name = "python",
- .version = PACKAGE_VERSION,
+ .name = "python",
+ .version = PACKAGE_VERSION,
- .load = py_load,
- .unload = py_unload,
- .dump_plugin = py_dump_plugin,
+ .load = py_load,
+ .unload = py_unload,
+ .dump_plugin = py_dump_plugin,
- .config = py_config,
- .config_complete = py_config_complete,
- .config_help = py_config_help,
+ .config = py...
2018 Apr 06
0
[nbdkit PATCH 1/2] python: Use Py_XDEFREF()
...>
---
plugins/python/python.c | 9 +++------
1 file changed, 3 insertions(+), 6 deletions(-)
diff --git a/plugins/python/python.c b/plugins/python/python.c
index 35e8df2..c5cc4bd 100644
--- a/plugins/python/python.c
+++ b/plugins/python/python.c
@@ -183,8 +183,7 @@ py_load (void)
static void
py_unload (void)
{
- if (module)
- Py_DECREF (module);
+ Py_XDECREF (module);
Py_Finalize ();
}
@@ -346,8 +345,7 @@ py_close (void *handle)
Py_DECREF (fn);
Py_DECREF (args);
check_python_failure ("close");
- if (r)
- Py_DECREF (r);
+ Py_XDECREF (r);
}
Py_...
2018 Apr 06
6
[nbdkit PATCH 0/2] Python cleanups
I noticed these while working on adding fua support into python,
these are independent enough to push now (and I'll have to rebase
my 'optional may_trim' patch on top of this).
Eric Blake (2):
python: Use Py_XDEFREF()
python: Simplify calling into plugin
plugins/python/python.c | 106 ++++++++----------------------------------------
1 file changed, 18 insertions(+), 88
2020 Sep 01
4
[nbdkit PATCH 0/2] More language bindings for .list_exports
This picks up python and ocaml. Some of our languages are lacking a
number of bindings (for example, lua and perl lack .extents, so I
didn't have anything to copy from), and I felt less comfortable with
golang and rust. But for python and ocaml, I was able to test a
working implementation.
Eric Blake (2):
python: Implement .list_exports and friends
ocaml: Implement .list_exports and
2020 Aug 05
5
[PATCH nbdkit 3/4] python: Allow thread model to be set from Python plugins.
This is working for me now, although possibly only on Python 3.9.
Dan suggested PyEval_InitThreads but that was deprecated in
Python 3.7.
Rich.
2020 Sep 21
18
[nbdkit PATCH v3 00/14] exportname filter
It's been several weeks since I posted v2 (I got distracted by
improving libnbd to better test things, which in turn surfaced some
major memory leak problems in nbdsh that are now fixed). Many of the
patches are minor rebases from v2, with the biggest changes being
fallout from:
- patch 2: rename nbdkit_add_default_export to nbdkit_use_default_export
- overall: this missed 1.22, so update