/* Set sync timeout in seconds. */ static void com_timeout(char *arg) { double timeout = 2.0; if (*arg != '\0') timeout = atof(arg); jack_set_sync_timeout(client, (jack_time_t) (timeout*1000000)); }
static PyObject* set_sync_timeout(PyObject* self, PyObject* args) { int time; if (! PyArg_ParseTuple(args, "i", &time)) return NULL; pyjack_client_t * client = self_or_global_client(self); if(client->pjc == NULL) { PyErr_SetString(JackNotConnectedError, "Jack connection has not yet been established."); return NULL; } jack_time_t timeout = time; jack_set_sync_timeout(client->pjc, timeout); return Py_None; }
int luajack_set_sync_timeout(luajack_t *client, jack_time_t timeout) { cud_t *cud = get_cud(client); if(!cud) return 0; return jack_set_sync_timeout(cud->client, timeout); }