Ruby 1.9 compatibility.

Fix error
  cannot load such file -- jcode

Fix unicode error for 1.9

Syntax error for 1.9 fix.