diff mbox series

suricatta/lua: Add suricatta.ipc.progress_cause table

Message ID 75BBC1C6-6DEC-4BB0-B4A9-17F8E748FA2B@siemens.com
State Accepted
Headers show
Series suricatta/lua: Add suricatta.ipc.progress_cause table | expand

Commit Message

Storm, Christian June 3, 2024, 8:16 p.m. UTC
Reported-by: Adithya Balakumar <adithya190298@gmail.com>
Signed-off-by: Christian Storm <christian.storm@siemens.com>
---
 suricatta/server_lua.c | 5 +++++
 1 file changed, 5 insertions(+)

Comments

Stefano Babic June 4, 2024, 1:34 p.m. UTC | #1
On 03.06.24 22:16, 'Storm, Christian' via swupdate wrote:
> Reported-by: Adithya Balakumar <adithya190298@gmail.com>
> Signed-off-by: Christian Storm <christian.storm@siemens.com>
> ---
>   suricatta/server_lua.c | 5 +++++
>   1 file changed, 5 insertions(+)
>
> diff --git a/suricatta/server_lua.c b/suricatta/server_lua.c
> index 7ac5e972..2641a037 100644
> --- a/suricatta/server_lua.c
> +++ b/suricatta/server_lua.c
> @@ -1592,6 +1592,11 @@ static int suricatta_lua_module(lua_State *L)
>   	push_to_table(L, "SUBPROCESS", SUBPROCESS);
>   	push_to_table(L, "PROGRESS", PROGRESS);
>   	lua_settable(L, -3);
> +	lua_pushstring(L, "progress_cause");
> +	lua_newtable(L);
> +	push_to_table(L, "CAUSE_NONE", CAUSE_NONE);
> +	push_to_table(L, "CAUSE_REBOOT_MODE", CAUSE_REBOOT_MODE);
> +	lua_settable(L, -3);
>   	lua_settable(L, -3);
>
>   	lua_pushstring(L, "status");

Applied to -master, thanks !

Best regards,
Stefano Babic
diff mbox series

Patch

diff --git a/suricatta/server_lua.c b/suricatta/server_lua.c
index 7ac5e972..2641a037 100644
--- a/suricatta/server_lua.c
+++ b/suricatta/server_lua.c
@@ -1592,6 +1592,11 @@  static int suricatta_lua_module(lua_State *L)
 	push_to_table(L, "SUBPROCESS", SUBPROCESS);
 	push_to_table(L, "PROGRESS", PROGRESS);
 	lua_settable(L, -3);
+	lua_pushstring(L, "progress_cause");
+	lua_newtable(L);
+	push_to_table(L, "CAUSE_NONE", CAUSE_NONE);
+	push_to_table(L, "CAUSE_REBOOT_MODE", CAUSE_REBOOT_MODE);
+	lua_settable(L, -3);
 	lua_settable(L, -3);
 
 	lua_pushstring(L, "status");