- Timestamp:
- Feb 11, 2011, 4:31:46 PM (14 years ago)
- Branches:
- master, release-1.10, release-1.8, release-1.9
- Children:
- 3472845
- Parents:
- ddbbcffa
- git-author:
- Anders Kaseorg <andersk@mit.edu> (08/27/09 00:55:10)
- git-committer:
- Anders Kaseorg <andersk@mit.edu> (02/11/11 16:31:46)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
zwrite.c
rddbbcffa rd4927a7 35 35 z->noping=0; 36 36 owl_list_create(&(z->recips)); 37 z->zwriteline = owl_strdup(line);37 z->zwriteline = g_strdup(line); 38 38 39 39 /* parse the command line for options */ … … 46 46 myargc=argc; 47 47 if (myargc && *(myargv[0])!='-') { 48 z->cmd= owl_strdup(myargv[0]);48 z->cmd=g_strdup(myargv[0]); 49 49 myargc--; 50 50 myargv++; … … 137 137 138 138 /* now deal with defaults */ 139 if (z->class==NULL) z->class= owl_strdup("message");140 if (z->inst==NULL) z->inst= owl_strdup("personal");141 if (z->realm==NULL) z->realm= owl_strdup("");142 if (z->opcode==NULL) z->opcode= owl_strdup("");139 if (z->class==NULL) z->class=g_strdup("message"); 140 if (z->inst==NULL) z->inst=g_strdup("personal"); 141 if (z->realm==NULL) z->realm=g_strdup(""); 142 if (z->opcode==NULL) z->opcode=g_strdup(""); 143 143 /* z->message is allowed to stay NULL */ 144 144 … … 178 178 to = owl_sprintf("%s@%s", (const char *) owl_list_get_element(&(z->recips), i), z->realm); 179 179 } else { 180 to = owl_strdup(owl_list_get_element(&(z->recips), i));180 to = g_strdup(owl_list_get_element(&(z->recips), i)); 181 181 } 182 182 send_ping(to, z->class, z->inst); … … 203 203 j=owl_list_get_size(&(z->recips)); 204 204 if (j>0 && z->cc) { 205 toline = owl_strdup( "CC: ");205 toline = g_strdup( "CC: "); 206 206 for (i=0; i<j; i++) { 207 207 tmp = toline; … … 252 252 to = owl_sprintf("%s@%s", (const char *) owl_list_get_element(&(z->recips), i), z->realm); 253 253 } else { 254 to = owl_strdup( owl_list_get_element(&(z->recips), i));254 to = g_strdup( owl_list_get_element(&(z->recips), i)); 255 255 } 256 256 ret = send_zephyr(z->opcode, z->zsig, z->class, z->inst, to, z->message); … … 319 319 { 320 320 if(z->zsig) g_free(z->zsig); 321 z->zsig = owl_strdup(zsig);321 z->zsig = g_strdup(zsig); 322 322 } 323 323
Note: See TracChangeset
for help on using the changeset viewer.