X-Git-Url: https://sigrok.org/gitweb/?a=blobdiff_plain;f=bindings%2Fpython%2Fsigrok%2Fcore%2Fclasses.i;h=eb557d0375335f561eb1e05d91f3536c38620c2f;hb=e333a40c1c5a27806b8a6dd2611c54b23d11366b;hp=94913d0f65caa052065a122070d9b48939e0d65a;hpb=a2916ad01779e1cf8a5e220eb6288dab9734b146;p=libsigrok.git diff --git a/bindings/python/sigrok/core/classes.i b/bindings/python/sigrok/core/classes.i index 94913d0f..eb557d03 100644 --- a/bindings/python/sigrok/core/classes.i +++ b/bindings/python/sigrok/core/classes.i @@ -344,8 +344,8 @@ Glib::VariantBase python_to_variant_by_key(PyObject *input, const sigrok::Config PyObject *numObj = PyTuple_GetItem(input, 0); PyObject *denomObj = PyTuple_GetItem(input, 1); if ((PyInt_Check(numObj) || PyLong_Check(numObj)) && (PyInt_Check(denomObj) || PyLong_Check(denomObj))) { - std::tuple tpl = {PyInt_AsLong(numObj), PyInt_AsLong(denomObj)}; - return Glib::Variant< std::tuple >::Variant::create(tpl); + const std::vector v = {(guint64)PyInt_AsLong(numObj), (guint64)PyInt_AsLong(denomObj)}; + return Glib::Variant< std::vector >::create(v); } } throw sigrok::Error(SR_ERR_ARG);