Index: channels/chan_gtalk.c =================================================================== --- channels/chan_gtalk.c (revision 48347) +++ channels/chan_gtalk.c (working copy) @@ -827,7 +827,7 @@ struct aji_resource *resources = NULL; struct aji_buddy *buddy; char idroster[200]; - char *data, *exten = NULL; + char *data = NULL, *exten = NULL, *cid = NULL; if (option_debug) ast_log(LOG_DEBUG, "The client is %s for alloc\n", client->name); @@ -872,6 +872,18 @@ return NULL; } + if (!strcasecmp(client->name, "guest")) { + if(strchr(tmp->them, '/')) { + data = ast_strdupa((char *) tmp->them); + cid = strsep(&data, "/"); + } else + cid = tmp->them; + } else { + cid = client->user; + } + ast_copy_string(tmp->cid_num, cid, sizeof(tmp->cid_num)); + ast_copy_string(tmp->cid_name, tmp->them, sizeof(tmp->cid_name)); + if(strchr(tmp->us, '/')) { data = ast_strdupa((char *) tmp->us); exten = strsep(&data, "/");