Skip to content

Commit 62bd8e7

Browse files
amstanmgeier
authored andcommitted
Made xrun callbacks a little easier
We now pass the delayed_usecs to the callback as an argument.
1 parent b56efbc commit 62bd8e7

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

jack.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1260,7 +1260,7 @@ def set_xrun_callback(self, callback):
12601260
User-supplied function that is called whenever an xrun has
12611261
occured. It must have this signature::
12621262
1263-
callback() -> None
1263+
callback(delayed_usecs:int) -> None
12641264
12651265
The `callback` is supposed to raise :class:`CallbackExit` on
12661266
error.
@@ -1273,7 +1273,7 @@ def set_xrun_callback(self, callback):
12731273
@self._callback("JackXRunCallback", error=_FAILURE)
12741274
def callback_wrapper(_):
12751275
try:
1276-
callback()
1276+
callback(self.xrun_delayed_usecs)
12771277
except CallbackExit:
12781278
return _FAILURE
12791279
return _SUCCESS

0 commit comments

Comments
 (0)