summaryrefslogtreecommitdiff
path: root/tools/fuzz.rb
diff options
context:
space:
mode:
Diffstat (limited to 'tools/fuzz.rb')
-rwxr-xr-xtools/fuzz.rb10
1 files changed, 1 insertions, 9 deletions
diff --git a/tools/fuzz.rb b/tools/fuzz.rb
index c0fae12..8261930 100755
--- a/tools/fuzz.rb
+++ b/tools/fuzz.rb
@@ -1,13 +1,5 @@
require 'json'
-require 'iconv'
-ISO_8859_1_TO_UTF8 = Iconv.new('utf-8', 'iso-8859-15')
-class ::String
- def to_utf8
- ISO_8859_1_TO_UTF8.iconv self
- end
-end
-
class Fuzzer
def initialize(n, freqs = {})
sum = freqs.inject(0.0) { |s, x| s + x.last }
@@ -25,7 +17,7 @@ class Fuzzer
def random_string
s = ''
30.times { s << @alpha[rand(@alpha.size)] }
- s.to_utf8
+ s
end
def pick