Lines Matching refs:new_s
1096 char *new_s; in mymemreplace() local
1128 new_s = (char *)PyMem_MALLOC(new_len); in mymemreplace()
1129 if (new_s == NULL) in mymemreplace()
1131 out_s = new_s; in mymemreplace()
1140 memcpy(new_s, str, offset); in mymemreplace()
1145 new_s += offset; in mymemreplace()
1146 memcpy(new_s, sub, sub_len); in mymemreplace()
1147 new_s += sub_len; in mymemreplace()
1151 memcpy(new_s, str, len); in mymemreplace()
1172 char *str, *pat,*sub,*new_s; in strop_replace() local
1192 new_s = mymemreplace(str,len,pat,pat_len,sub,sub_len,count,&out_len); in strop_replace()
1193 if (new_s == NULL) { in strop_replace()
1203 newstr = PyString_FromStringAndSize(new_s, out_len); in strop_replace()
1204 PyMem_FREE(new_s); in strop_replace()