Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion cups/dnssd.c
Original file line number Diff line number Diff line change
Expand Up @@ -2606,10 +2606,11 @@ win32_utf8cpy(char *dst, // I - Destination string
size_t dstsize) // I - Size of destination string
{
int ch; // Current character
char *dstend = dst + dstsize - 5; // End of destination string


// Loop until we run out of characters or buffer space...
while (*src && dstsize > 4)
while (*src && dst <= dstend)
{
// Get the current character...
ch = *src++;
Expand Down
Loading