mirror of
https://github.com/david-schmidt/gsport.git
synced 2024-06-08 12:29:31 +00:00
Skip the leading return character when this is the first line in the paste buffer
This commit is contained in:
parent
8b8e9b32dc
commit
b93084200a
|
@ -533,7 +533,9 @@ clipboard_paste(void)
|
||||||
bufsize += CHUNK_SIZE + 1;
|
bufsize += CHUNK_SIZE + 1;
|
||||||
expanding_buffer = realloc(expanding_buffer, bufsize);
|
expanding_buffer = realloc(expanding_buffer, bufsize);
|
||||||
}
|
}
|
||||||
strcat((char*)expanding_buffer,"\r");
|
/* Skip the leading return character when this is the first line in the paste buffer */
|
||||||
|
if (strlen((char*)expanding_buffer) > 0)
|
||||||
|
strcat((char*)expanding_buffer,"\r");
|
||||||
strncat((char*)expanding_buffer,buffer,strlen(buffer));
|
strncat((char*)expanding_buffer,buffer,strlen(buffer));
|
||||||
g_clipboard = (char*)expanding_buffer;
|
g_clipboard = (char*)expanding_buffer;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user