(b *gather.WriteBuffer, count int)
| 89 | } |
| 90 | |
| 91 | func writeRandomBytesToBuffer(b *gather.WriteBuffer, count int) error { |
| 92 | var rnd [defaultPaddingUnit]byte |
| 93 | |
| 94 | if _, err := io.ReadFull(cryptorand.Reader, rnd[0:count]); err != nil { |
| 95 | return errors.Wrap(err, "error getting random bytes") |
| 96 | } |
| 97 | |
| 98 | b.Append(rnd[0:count]) |
| 99 | |
| 100 | return nil |
| 101 | } |
| 102 | |
| 103 | func contentCacheKeyForInfo(bi Info) string { |
| 104 | // append format-specific information |
no test coverage detected