shared/shell: Add bt_shell_get_timeout()
authorBastien Nocera <hadess@hadess.net>
Thu, 12 Sep 2024 09:20:10 +0000 (11:20 +0200)
committerWootak Jung <wootak.jung@samsung.com>
Thu, 20 Feb 2025 07:43:23 +0000 (16:43 +0900)
Make it possible to get the value of the general --timeout option.

Signed-off-by: Anuj Jain <anuj01.jain@samsung.com>
src/shared/shell.c
src/shared/shell.h

index cb368182585785f2c4d292cb0f03868140e3d666..ab1738a3bcdfee2218920dbb14769464ff821f30 100644 (file)
@@ -1669,3 +1669,8 @@ void *bt_shell_get_env(const char *name)
 
        return env->value;
 }
+
+int bt_shell_get_timeout(void)
+{
+       return data.timeout;
+}
index a9a635bda959eb7ce5e4aef21cac8ba7c4c217bd..b03250cac80fd39796880aaa55a404792d70e1ac 100644 (file)
@@ -85,4 +85,6 @@ bool bt_shell_detach(void);
 void bt_shell_set_env(const char *name, void *value);
 void *bt_shell_get_env(const char *name);
 
+int bt_shell_get_timeout(void);
+
 void bt_shell_cleanup(void);