Skip to content

Commit 442914c

Browse files
tleguernpasis
authored andcommitted
Shorten the nlen+dlen+rlen part
1 parent a4558b6 commit 442914c

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/jid.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ char *xmpp_jid_new(xmpp_ctx_t *ctx, const char *node,
5656
result[nlen+dlen] = '/';
5757
memcpy(result+nlen+dlen+1, resource, rlen - 1);
5858
}
59-
result[nlen+dlen+rlen] = '\0';
59+
result[len] = '\0';
6060
}
6161

6262
return result;

0 commit comments

Comments
 (0)