comparison scripts/audio/@audioplayer/playblocking.m @ 31229:c967e74cc053

playblocking.m: Fix regression introduced in cset 6d96538052b9 (bug #63061) * playblocking.m: Rename second input to "start" to avoid collision with built-in function "length". Only pass second argument to internal function __player_playblocking__ if second argument as given to playblocking().
author Rik <rik@octave.org>
date Thu, 15 Sep 2022 16:59:09 -0700
parents 6d96538052b9
children 597f3ee61a48
comparison
equal deleted inserted replaced
31228:4c1be4d6d0d1 31229:c967e74cc053
37 ## @var{end} samples into the recording. 37 ## @var{end} samples into the recording.
38 ## @seealso{@audioplayer/play, @audioplayer/pause, @audioplayer/stop, 38 ## @seealso{@audioplayer/play, @audioplayer/pause, @audioplayer/stop,
39 ## @audioplayer/audioplayer} 39 ## @audioplayer/audioplayer}
40 ## @end deftypefn 40 ## @end deftypefn
41 41
42 function playblocking (player, length) 42 function playblocking (player, start)
43 43
44 if (nargin != 2) 44 if (nargin == 1)
45 print_usage (); 45 __player_playblocking__ (struct (player).player);
46 else
47 __player_playblocking__ (struct (player).player, start);
46 endif 48 endif
47
48 __player_playblocking__ (struct (player).player, length);
49 49
50 endfunction 50 endfunction
51 51
52 52
53 ## No tests possible for this function 53 ## No tests possible for this function