Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
| ... | ... |
@@ -174,7 +174,7 @@ func (ld *v2LayerDescriptor) Download(ctx context.Context, progressOutput progre |
| 174 | 174 |
return nil, 0, xfer.DoNotRetry{Err: err}
|
| 175 | 175 |
} |
| 176 | 176 |
} else {
|
| 177 |
- offset, err = ld.tmpFile.Seek(0, os.SEEK_END) |
|
| 177 |
+ offset, err = ld.tmpFile.Seek(0, io.SeekEnd) |
|
| 178 | 178 |
if err != nil {
|
| 179 | 179 |
logrus.Debugf("error seeking to end of download file: %v", err)
|
| 180 | 180 |
offset = 0 |
| ... | ... |
@@ -209,7 +209,7 @@ func (ld *v2LayerDescriptor) Download(ctx context.Context, progressOutput progre |
| 209 | 209 |
return nil, 0, err |
| 210 | 210 |
} |
| 211 | 211 |
} |
| 212 |
- size, err := layerDownload.Seek(0, os.SEEK_END) |
|
| 212 |
+ size, err := layerDownload.Seek(0, io.SeekEnd) |
|
| 213 | 213 |
if err != nil {
|
| 214 | 214 |
// Seek failed, perhaps because there was no Content-Length |
| 215 | 215 |
// header. This shouldn't fail the download, because we can |