fix potential seg fault in my patch that just went in, oops
authorRussell Bryant <russell@russellbryant.com>
Fri, 15 Apr 2005 06:55:21 +0000 (06:55 +0000)
committerRussell Bryant <russell@russellbryant.com>
Fri, 15 Apr 2005 06:55:21 +0000 (06:55 +0000)
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@5473 65c4cc65-6c06-0410-ace0-fbb531ad65f3

channels/chan_agent.c

index 38d6f6d..ac8be55 100755 (executable)
@@ -300,7 +300,7 @@ static struct agent_pvt *add_agent(char *agent, int pending)
        }
        
        strncpy(p->password, password ? password : "", sizeof(p->password) - 1);
-       strncpy(p->name, !ast_strlen_zero(name) ? name : "---", sizeof(p->name) - 1);
+       strncpy(p->name, name ? name : "", sizeof(p->name) - 1);
        strncpy(p->moh, moh, sizeof(p->moh) - 1);
        p->ackcall = ackcall;
        p->autologoff = autologoff;