[Asterisk-code-review] pbx_variables: initialize uninitialized variable (asterisk[18])
N A
asteriskteam at digium.com
Tue Dec 14 17:21:49 CST 2021
N A has uploaded this change for review. ( https://gerrit.asterisk.org/c/asterisk/+/17689 )
Change subject: pbx_variables: initialize uninitialized variable
......................................................................
pbx_variables: initialize uninitialized variable
The variable cp4 in a variable substitution function
can potentially be used without being initialized
currently. This causes Asterisk to no longer compile.
This initializes cp4 to NULL to make the compiler
happy.
ASTERISK-29803 #close
Change-Id: I392579cbb76db2795d5820c9427cf55fbcee9e72
---
M main/pbx_variables.c
1 file changed, 1 insertion(+), 1 deletion(-)
git pull ssh://gerrit.asterisk.org:29418/asterisk refs/changes/89/17689/1
diff --git a/main/pbx_variables.c b/main/pbx_variables.c
index 2088740..7a85989 100644
--- a/main/pbx_variables.c
+++ b/main/pbx_variables.c
@@ -692,7 +692,7 @@
int offset;
int offset2;
int isfunction;
- char *cp4;
+ char *cp4 = NULL;
char workspace[VAR_BUF_SIZE] = "";
/* We have a variable. Find the start and end, and determine
--
To view, visit https://gerrit.asterisk.org/c/asterisk/+/17689
To unsubscribe, or for help writing mail filters, visit https://gerrit.asterisk.org/settings
Gerrit-Project: asterisk
Gerrit-Branch: 18
Gerrit-Change-Id: I392579cbb76db2795d5820c9427cf55fbcee9e72
Gerrit-Change-Number: 17689
Gerrit-PatchSet: 1
Gerrit-Owner: N A <mail at interlinked.x10host.com>
Gerrit-MessageType: newchange
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.digium.com/pipermail/asterisk-code-review/attachments/20211214/e107d6c4/attachment-0001.html>
More information about the asterisk-code-review
mailing list