[Asterisk-cvs] asterisk asterisk.c,1.112,1.113
markster at lists.digium.com
markster at lists.digium.com
Thu Aug 5 17:36:56 CDT 2004
Update of /usr/cvsroot/asterisk
In directory localhost.localdomain:/tmp/cvs-serv20326
Modified Files:
asterisk.c
Log Message:
Fix verboser issue over network (#2217)
Index: asterisk.c
===================================================================
RCS file: /usr/cvsroot/asterisk/asterisk.c,v
retrieving revision 1.112
retrieving revision 1.113
diff -u -d -r1.112 -r1.113
--- asterisk.c 3 Aug 2004 06:31:20 -0000 1.112
+++ asterisk.c 5 Aug 2004 21:22:56 -0000 1.113
@@ -233,7 +233,18 @@
static void network_verboser(const char *s, int pos, int replace, int complete)
/* ARGUSED */
{
- ast_network_puts(s);
+ if (replace) {
+ char *t = alloca(strlen(s) + 2);
+ if (t) {
+ sprintf(t, "\r%s", s);
+ ast_network_puts(t);
+ } else {
+ ast_log(LOG_ERROR, "Out of memory\n");
+ ast_network_puts(s);
+ }
+ } else {
+ ast_network_puts(s);
+ }
}
static pthread_t lthread;
More information about the svn-commits
mailing list