INNER CODE UNIT · Go

footerLen

GGP1/kure · commands/util.go:170

	footerLen := longestKey + longestValue + 5
	sb.WriteString(lowerLeft)
	sb.WriteString(strings.Repeat(hBar, footerLen))
	sb.WriteString(lowerRight)

	return sb.String()
}

// Erase overwrites the file content with random bytes and then deletes it.
func Erase(filename string) error {
	f, err := os.Stat(filename)
	if err != nil {
		return errors.Wrap(err, "obtaining file information")
	}

	buf := make([]byte, f.Size())
	_, _ = rand.Read(buf)

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…