Q_strlcat minor bugfix

This commit is contained in:
svdijk 2013-05-18 21:07:52 +02:00
parent 5692388da1
commit 1d0f979bf9

View file

@ -1152,12 +1152,13 @@ Q_strlcat(char *dst, const char *src, int size)
{
char *d = dst;
while (*d)
while (size > 0 && *d)
{
size--;
d++;
}
return (d - dst) + Q_strlcpy(d, src, size - (d - dst));
return (d - dst) + Q_strlcpy(d, src, size);
}
/*