]> git.ipfire.org Git - thirdparty/asterisk.git/commitdiff
Use the correct variable when creating the format string
authorMark Michelson <mmichelson@digium.com>
Tue, 6 Jan 2009 21:35:57 +0000 (21:35 +0000)
committerMark Michelson <mmichelson@digium.com>
Tue, 6 Jan 2009 21:35:57 +0000 (21:35 +0000)
(closes issue #14177)
Reported by: nic_bellamy
Patches:
      asterisk-trunk-svn-r167242-ast_db_gettree.patch uploaded by nic (license 299)

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@167299 65c4cc65-6c06-0410-ace0-fbb531ad65f3

main/db.c

index ef381c092a837c6f248f1ee8eb2e569a386cb0a7..3e61be50950e5b9e8597f1cf2d166905e0043b8b 100644 (file)
--- a/main/db.c
+++ b/main/db.c
@@ -407,7 +407,7 @@ struct ast_db_entry *ast_db_gettree(const char *family, const char *keytree)
        if (!ast_strlen_zero(family)) {
                if (!ast_strlen_zero(keytree)) {
                        /* Family and key tree */
-                       snprintf(prefix, sizeof(prefix), "/%s/%s", family, prefix);
+                       snprintf(prefix, sizeof(prefix), "/%s/%s", family, keytree);
                } else {
                        /* Family only */
                        snprintf(prefix, sizeof(prefix), "/%s", family);