File tree 1 file changed +4
-4
lines changed 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -148,7 +148,7 @@ func GenerateDomain(r *rand.Rand, size int) []byte {
148
148
}
149
149
lLen := max
150
150
if lLen != 0 {
151
- lLen = int (r .Uint32 ()) % max
151
+ lLen = int (r .Int31 ()) % max
152
152
}
153
153
done = lLen == 0
154
154
if done {
@@ -157,7 +157,7 @@ func GenerateDomain(r *rand.Rand, size int) []byte {
157
157
l := make ([]byte , lLen + 1 )
158
158
l [0 ] = byte (lLen )
159
159
for j := 0 ; j < lLen ; j ++ {
160
- l [j + 1 ] = byte (rand .Uint32 ())
160
+ l [j + 1 ] = byte (rand .Int31 ())
161
161
}
162
162
dn = append (dn , l ... )
163
163
i += 1 + lLen
@@ -205,12 +205,12 @@ func GenerateTXT(r *rand.Rand, size int) []byte {
205
205
}
206
206
sLen := max
207
207
if max != 0 {
208
- sLen = int (r .Uint32 ()) % max
208
+ sLen = int (r .Int31 ()) % max
209
209
}
210
210
s := make ([]byte , sLen + 1 )
211
211
s [0 ] = byte (sLen )
212
212
for j := 0 ; j < sLen ; j ++ {
213
- s [j + 1 ] = byte (rand .Uint32 ())
213
+ s [j + 1 ] = byte (rand .Int31 ())
214
214
}
215
215
rd = append (rd , s ... )
216
216
i += 1 + sLen
You can’t perform that action at this time.
0 commit comments