Commit 82ad42de authored by Christopher Schinnerl's avatar Christopher Schinnerl

Custom erasure code settings should also use NewRSSubCode

parent dd9b3bdb
Pipeline #57383447 failed with stages
in 2 minutes and 48 seconds
......@@ -58,7 +58,7 @@ func (r *Renter) Upload(up modules.FileUploadParams) error {
// Fill in any missing upload params with sensible defaults.
if up.ErasureCode == nil {
up.ErasureCode, _ = siafile.NewRSSubCode(defaultDataPieces, defaultParityPieces, 64)
up.ErasureCode, _ = siafile.NewRSSubCode(defaultDataPieces, defaultParityPieces, crypto.SegmentSize)
}
// Check that we have contracts to upload to. We need at least data +
......
......@@ -291,7 +291,7 @@ func parseErasureCodingParameters(strDataPieces, strParityPieces string) (module
}
// Create the erasure coder.
return siafile.NewRSCode(dataPieces, parityPieces)
return siafile.NewRSSubCode(dataPieces, parityPieces, crypto.SegmentSize)
}
return nil, nil
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment