Skip to content

Commit

Permalink
xcap_server: rever use of STR_VTOZ macro
Browse files Browse the repository at this point in the history
- got it by picking a commit with another fix and this macro is not in
branch 5.3
  • Loading branch information
miconda committed Sep 10, 2020
1 parent 39e088f commit 82f82fc
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/modules/xcap_server/xcap_server.c
Expand Up @@ -321,12 +321,13 @@ int xcaps_xpath_hack(str *buf, int type)
}

start = buf->s;
STR_VTOZ(buf->s[buf->len-1], c);
c = buf->s[buf->len-1];
buf->s[buf->len-1] = '\0';
while((start < buf->s + buf->len - 8) && (p = strstr(start, match))!=NULL) {
memcpy(p, repl, 7);
start = p + 7;
}
STR_ZTOV(buf->s[buf->len-1], c);
buf->s[buf->len-1] = c;
return 0;
}

Expand Down

0 comments on commit 82f82fc

Please sign in to comment.