package main
import (
- "bytes"
"encoding/hex"
"errors"
"io"
if err != nil {
return ErrLine(err)
}
- if !bytes.Equal(hsh, theirHsh) {
+ if hsh != string(theirHsh) {
tracef(
CDebug, "depfix: %s/%s -> %s: hash differs",
root, entry.Name(), dep,
fields = []recfile.Field{
{Name: "Type", Value: DepTypeIfchange},
{Name: "Target", Value: dep},
- {Name: "Hash", Value: hex.EncodeToString(hsh)},
+ {Name: "Hash", Value: hex.EncodeToString([]byte(hsh))},
}
fields = append(fields, inode.RecfileFields()...)
fieldses[len(fieldses)-1] = fields