projects
/
qemu-gpiodev
/
libgpiod.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
f7e284e
)
bindings: python: call gpiod_LineBulk_init() directly
author
Bartosz Golaszewski
<bartekgola@gmail.com>
Fri, 13 Jul 2018 13:57:25 +0000
(15:57 +0200)
committer
Bartosz Golaszewski
<bartekgola@gmail.com>
Fri, 13 Jul 2018 13:58:27 +0000
(15:58 +0200)
Using the .tp_init callback is more complicated and unnecessary. Call
gpiod_LineBulk_init() directly from gpiod_ListToLineBulk().
Signed-off-by: Bartosz Golaszewski <bartekgola@gmail.com>
bindings/python/gpiodmodule.c
patch
|
blob
|
history
diff --git
a/bindings/python/gpiodmodule.c
b/bindings/python/gpiodmodule.c
index b45ce6604a17a9f101ae36fe1ebdb633896825bc..0d10814527ad1d2f78902fc968addc25715b14bd 100644
(file)
--- a/
bindings/python/gpiodmodule.c
+++ b/
bindings/python/gpiodmodule.c
@@
-1479,7
+1479,7
@@
static gpiod_LineBulkObject *gpiod_ListToLineBulk(PyObject *lines)
return NULL;
}
- rv = gpiod_LineBulk
Type.tp_init((PyObject *)bulk, arg, NULL
);
+ rv = gpiod_LineBulk
_init(bulk, arg
);
Py_DECREF(arg);
if (rv < 0) {
Py_DECREF(bulk);