make Local channel return sensible device state values
authorKevin P. Fleming <kpfleming@digium.com>
Wed, 14 Jun 2006 22:39:19 +0000 (22:39 +0000)
committerKevin P. Fleming <kpfleming@digium.com>
Wed, 14 Jun 2006 22:39:19 +0000 (22:39 +0000)
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@34162 65c4cc65-6c06-0410-ace0-fbb531ad65f3

channels/chan_local.c

index 68dbd7d..a865aa6 100644 (file)
@@ -134,9 +134,9 @@ static int local_devicestate(void *data)
                ast_log(LOG_DEBUG, "Checking if extension %s@%s exists (devicestate)\n", exten, context);
        res = ast_exists_extension(NULL, context, exten, 1, NULL);
        if (!res)
-               return AST_DEVICE_NOT_INUSE;
+               return AST_DEVICE_INVALID;
        else
-               return AST_DEVICE_INUSE;
+               return AST_DEVICE_UNKNOWN;
 }
 
 static int local_queue_frame(struct local_pvt *p, int isoutbound, struct ast_frame *f, struct ast_channel *us)