summaryrefslogtreecommitdiff
path: root/server.rb
diff options
context:
space:
mode:
authorPatrick Simianer <p@simianer.de>2015-05-18 10:45:50 +0200
committerPatrick Simianer <p@simianer.de>2015-05-18 10:45:50 +0200
commite820e38159390093cdcbf08b2f1a8b7eb0632278 (patch)
treefee8154d32c49d407ee606e996139f14c2a342a1 /server.rb
parentcaf5f8402d8a621ca39cb45a8f29d2f084381141 (diff)
fix
Diffstat (limited to 'server.rb')
-rwxr-xr-xserver.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/server.rb b/server.rb
index 2112638..86fc53f 100755
--- a/server.rb
+++ b/server.rb
@@ -119,7 +119,7 @@ get '/next' do
STDERR.write "[dtrain] > asking to translate: '#{msg}'\n"
env[:dtrain][:socket].send msg
STDERR.write "[dtrain] waiting for translation ...\n"
- transl = env[:dtrain][:socket].recv.encode "UTF-8"
+ transl = env[:dtrain][:socket].recv.force_encoding "UTF-8"
STDERR.write "[dtrain] < received translation: '#{transl}'\n"
"#{source}\t#{transl}"
end