Skip to content
This repository has been archived by the owner on Oct 8, 2019. It is now read-only.

Commit

Permalink
Fixes for changes in the type of seed
Browse files Browse the repository at this point in the history
  • Loading branch information
myui committed Jun 7, 2016
1 parent a23062b commit cf28b83
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ public StructObjectInspector initialize(ObjectInspector[] argOIs) throws UDFArgu
Field rnd2 = clazz.getDeclaredField("rnd2");
Field r_seed = clazz.getDeclaredField("r_seed");
r_seed.setAccessible(true);
final int seed = r_seed.getInt(udtf) + (int) Thread.currentThread().getId();
final long seed = r_seed.getLong(udtf) + (int) Thread.currentThread().getId();
rnd1.setAccessible(true);
rnd2.setAccessible(true);
rnd1.set(udtf, new Random(seed));
Expand Down

0 comments on commit cf28b83

Please sign in to comment.