diff options
author | 2016-08-29 09:27:12 -0400 | |
---|---|---|
committer | 2016-08-29 09:27:12 -0400 | |
commit | ffb0f99b7ba6032d3a5c90dfd10ccffe9941dbfa (patch) | |
tree | b2487761e1461d2cfdf82cfb0e25916ebff9e4f9 /modules/textadept | |
parent | 1d1259196c1fcfb7daab6c987d13a57672a4f4d6 (diff) | |
download | textadept-ffb0f99b7ba6032d3a5c90dfd10ccffe9941dbfa.tar.gz textadept-ffb0f99b7ba6032d3a5c90dfd10ccffe9941dbfa.zip |
Fixed potential crash on Windows with filter-through and some locales.
cmd.exe can choke on outputting some non-ASCII characters.
Diffstat (limited to 'modules/textadept')
-rw-r--r-- | modules/textadept/editing.lua | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/modules/textadept/editing.lua b/modules/textadept/editing.lua index f3c7223a..238db220 100644 --- a/modules/textadept/editing.lua +++ b/modules/textadept/editing.lua @@ -518,7 +518,7 @@ function M.filter_through(command) local p = spawn(command) p:write(buffer.target_text) p:close() - buffer:replace_target(p:read('*a')) + buffer:replace_target(p:read('*a'):iconv('UTF-8', _CHARSET)) if s ~= e then buffer:set_sel(buffer.target_start, buffer.target_end) else |