From fa0536aab922491c9865771f16e41702f6a08165 Mon Sep 17 00:00:00 2001
From: Russell Bryant <russell@russellbryant.com>
Date: Thu, 6 Sep 2007 20:27:26 +0000
Subject: [PATCH] Rename the DEVSTATE() function to DEVICE_STATE() to better
 conform to how other functions are named. (inspired by issue #10635)

git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@81784 65c4cc65-6c06-0410-ace0-fbb531ad65f3
---
 funcs/func_devstate.c | 22 +++++++++++-----------
 1 file changed, 11 insertions(+), 11 deletions(-)

diff --git a/funcs/func_devstate.c b/funcs/func_devstate.c
index 7ed389c9bd..6ee68c7f6c 100644
--- a/funcs/func_devstate.c
+++ b/funcs/func_devstate.c
@@ -58,12 +58,12 @@ static int devstate_write(struct ast_channel *chan, const char *cmd, char *data,
 	size_t len = strlen("Custom:");
 
 	if (strncasecmp(data, "Custom:", len)) {
-		ast_log(LOG_WARNING, "The DEVSTATE function can only be used to set 'Custom:' device state!\n");
+		ast_log(LOG_WARNING, "The DEVICE_STATE function can only be used to set 'Custom:' device state!\n");
 		return -1;
 	}
 	data += len;
 	if (ast_strlen_zero(data)) {
-		ast_log(LOG_WARNING, "DEVSTATE function called with no custom device name!\n");
+		ast_log(LOG_WARNING, "DEVICE_STATE function called with no custom device name!\n");
 		return -1;
 	}
 
@@ -139,7 +139,7 @@ static char *cli_funcdevstate_list(struct ast_cli_entry *e, int cmd, struct ast_
 		e->usage =
 			"Usage: funcdevstate list\n"
 			"       List all custom device states that have been set by using\n"
-			"       the DEVSTATE dialplan function.\n";
+			"       the DEVICE_STATE dialplan function.\n";
 		return NULL;
 	case CLI_GENERATE:
 		return NULL;
@@ -178,19 +178,19 @@ static struct ast_cli_entry cli_funcdevstate[] = {
 };
 
 static struct ast_custom_function devstate_function = {
-	.name = "DEVSTATE",
+	.name = "DEVICE_STATE",
 	.synopsis = "Get or Set a device state",
-	.syntax = "DEVSTATE(device)",
+	.syntax = "DEVICE_STATE(device)",
 	.desc =
-	"  The DEVSTATE function can be used to retrieve the device state from any\n"
+	"  The DEVICE_STATE function can be used to retrieve the device state from any\n"
 	"device state provider.  For example:\n"
-	"   NoOp(SIP/mypeer has state ${DEVSTATE(SIP/mypeer)})\n"
-	"   NoOp(Conference number 1234 has state ${DEVSTATE(MeetMe:1234)})\n"
+	"   NoOp(SIP/mypeer has state ${DEVICE_STATE(SIP/mypeer)})\n"
+	"   NoOp(Conference number 1234 has state ${DEVICE_STATE(MeetMe:1234)})\n"
 	"\n"
-	"  The DEVSTATE function can also be used to set custom device state from\n"
+	"  The DEVICE_STATE function can also be used to set custom device state from\n"
 	"the dialplan.  The \"Custom:\" prefix must be used.  For example:\n"
-	"  Set(DEVSTATE(Custom:lamp1)=BUSY)\n"
-	"  Set(DEVSTATE(Custom:lamp2)=NOT_INUSE)\n"
+	"  Set(DEVICE_STATE(Custom:lamp1)=BUSY)\n"
+	"  Set(DEVICE_STATE(Custom:lamp2)=NOT_INUSE)\n"
 	"You can subscribe to the status of a custom device state using a hint in\n"
 	"the dialplan:\n"
 	"  exten => 1234,hint,Custom:lamp1\n"
-- 
GitLab