summaryrefslogtreecommitdiff
path: root/apps/plugins/lua
diff options
context:
space:
mode:
Diffstat (limited to 'apps/plugins/lua')
-rw-r--r--apps/plugins/lua/rocklib.c4
-rw-r--r--apps/plugins/lua/rocklib.h2
2 files changed, 3 insertions, 3 deletions
diff --git a/apps/plugins/lua/rocklib.c b/apps/plugins/lua/rocklib.c
index ed625ca..44eb549 100644
--- a/apps/plugins/lua/rocklib.c
+++ b/apps/plugins/lua/rocklib.c
@@ -363,7 +363,7 @@ RB_WRAP(pcm)
lua_pushboolean(L, b_result);
break;
case PCM_PLAYPAUSE:
- rb->pcm_play_pause(luaL_checkboolean(L, 1));
+ rb->pcm_play_pause(luaL_checkboolean(L, 2));
break;
case PCM_PLAYSTOP:
rb->pcm_play_stop();
@@ -380,7 +380,7 @@ RB_WRAP(pcm)
lua_pushinteger(L, right);
return 2;
case PCM_SETFREQUENCY:
- rb->pcm_set_frequency((unsigned int) luaL_checkint(L, 1));
+ rb->pcm_set_frequency((unsigned int) luaL_checkint(L, 2));
break;
case PCM_GETBYTESWAITING:
byteswait = rb->pcm_get_bytes_waiting();
diff --git a/apps/plugins/lua/rocklib.h b/apps/plugins/lua/rocklib.h
index 4714dec..c8d1366 100644
--- a/apps/plugins/lua/rocklib.h
+++ b/apps/plugins/lua/rocklib.h
@@ -33,7 +33,7 @@
#endif
#define RB_CONSTANT(x) {#x, x}
-#define RB_STRING_CONSTANT(x) RB_CONSTANT(x)
+#define RB_STRING_CONSTANT(x) {#x, x}
struct lua_int_reg {
char const* name;