gst/gstelement.override (_wrap_gst_element_get_state): Set the timeout to 0 as default

Original commit message from CVS:
* gst/gstelement.override (_wrap_gst_element_get_state): Set the
timeout to 0 as default
This commit is contained in:
Johan Dahlin 2005-09-29 02:38:07 +00:00
parent 2d13103ff7
commit e07e65d842
2 changed files with 9 additions and 2 deletions

View file

@ -1,3 +1,8 @@
2005-09-28 Johan Dahlin <johan@gnome.org>
* gst/gstelement.override (_wrap_gst_element_get_state): Set the
timeout to 0 as default
2005-09-28 Edward Hervey <edward@fluendo.com>
* gst/gst.defs:

View file

@ -81,13 +81,13 @@ _wrap_gst_element_get_state(PyGObject *self, PyObject *args, PyObject *kwargs)
GstState state;
GstState pending;
GstStateChangeReturn ret;
PyObject *timeout;
PyObject *timeout = Py_None;
GTimeVal *timevalp = NULL;
GTimeVal timeval;
PyObject *tuple;
if (!PyArg_ParseTupleAndKeywords(args, kwargs,
"O:GstElement.get_state", kwlist,
"|O:GstElement.get_state", kwlist,
&timeout)) {
PyErr_SetString(PyExc_RuntimeError, "Timeout not specified correctly");
return NULL;
@ -105,6 +105,8 @@ _wrap_gst_element_get_state(PyGObject *self, PyObject *args, PyObject *kwargs)
timeval.tv_usec = (glong) ((timeoutd - (gdouble) timeval.tv_sec)
* 1000.0 * 1000.0);
timevalp = &timeval;
} else {
GST_TIME_TO_TIMEVAL (0, timeval);
}
ret = gst_element_get_state(GST_ELEMENT (self->obj), &state, &pending,