From fbaf74bd3a24ee9ef02fe63aab15e60288b00af5 Mon Sep 17 00:00:00 2001
From: Naveen Albert <asterisk@phreaknet.org>
Date: Sat, 8 Jan 2022 15:09:13 +0000
Subject: [PATCH] pbx_variables: add missing ASTSBINDIR variable

Every config variable in the directories
section of asterisk.conf currently has a
counterpart built-in variable containing
the value of the config option, except
for the last one, astsbindir, which should
have an ASTSBINDIR variable.

However, the actual corresponding ASTSBINDIR
variable is missing in pbx_variables.c.

This adds the missing variable so that all
the config options have their corresponding
variable.

ASTERISK-29847 #close

Change-Id: I36006faf471825b36ebc8aa5e87a3bcb38d446fc
---
 main/pbx_variables.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/main/pbx_variables.c b/main/pbx_variables.c
index 7a859890c3..6f7439f72f 100644
--- a/main/pbx_variables.c
+++ b/main/pbx_variables.c
@@ -350,6 +350,8 @@ const char *ast_str_retrieve_variable(struct ast_str **str, ssize_t maxlen, stru
 			s = ast_config_AST_RUN_DIR;
 		} else if (!strcmp(var, "ASTLOGDIR")) {
 			s = ast_config_AST_LOG_DIR;
+		} else if (!strcmp(var, "ASTSBINDIR")) {
+			s = ast_config_AST_SBIN_DIR;
 		} else if (!strcmp(var, "ENTITYID")) {
 			ast_eid_to_str(workspace, sizeof(workspace), &ast_eid_default);
 			s = workspace;
-- 
GitLab