mirror of
https://github.com/neovim/neovim.git
synced 2025-09-08 04:18:18 +00:00
paste: break lines at CR, CRLF #10877
Some terminals helpfully translate \n to \r. fix #10872 ref #10223
This commit is contained in:
@@ -1247,7 +1247,7 @@ Boolean nvim_paste(String data, Integer phase, Error *err)
|
||||
// Skip remaining chunks. Report error only once per "stream".
|
||||
goto theend;
|
||||
}
|
||||
Array lines = string_to_array(data);
|
||||
Array lines = string_to_array(data, true);
|
||||
ADD(args, ARRAY_OBJ(lines));
|
||||
ADD(args, INTEGER_OBJ(phase));
|
||||
rv = nvim_execute_lua(STATIC_CSTR_AS_STRING("return vim.paste(...)"), args,
|
||||
|
Reference in New Issue
Block a user