|
@@ -397,11 +397,11 @@ func (server *Server) createListener(addr string, tlsConfig *tls.Config) *Listen
|
397
|
397
|
func (server *Server) generateMessageID() string {
|
398
|
398
|
// we don't need the full like 30 chars since the unixnano below handles
|
399
|
399
|
// most of our uniqueness requirements, so just truncate at 5
|
400
|
|
- lastbit := strconv.FormatInt(rand.Int63(), 16)
|
|
400
|
+ lastbit := strconv.FormatInt(rand.Int63(), 36)
|
401
|
401
|
if 5 < len(lastbit) {
|
402
|
|
- lastbit = lastbit[:5]
|
|
402
|
+ lastbit = lastbit[:4]
|
403
|
403
|
}
|
404
|
|
- return fmt.Sprintf("%s%s", strconv.FormatInt(time.Now().UTC().UnixNano(), 16), lastbit)
|
|
404
|
+ return fmt.Sprintf("%s%s", strconv.FormatInt(time.Now().UTC().UnixNano(), 36), lastbit)
|
405
|
405
|
}
|
406
|
406
|
|
407
|
407
|
//
|