mirror of
https://github.com/balena-io/etcher.git
synced 2025-07-23 03:06:38 +00:00
Merge branch 'master' into update-drivelist-6.4.0
This commit is contained in:
commit
6a0198639f
@ -515,6 +515,12 @@ class ImageWriter extends EventEmitter {
|
|||||||
const pipeline = this._createVerifyPipeline(destination)
|
const pipeline = this._createVerifyPipeline(destination)
|
||||||
|
|
||||||
pipeline.on('error', (error) => {
|
pipeline.on('error', (error) => {
|
||||||
|
// NOTE: As the `blockmap` module doesn't set our custom error codes,
|
||||||
|
// we need to patch `EVALIDATION` into a range checksum error here
|
||||||
|
if (error.message && error.message.startsWith('Invalid checksum for range')) {
|
||||||
|
error.code = 'EVALIDATION'
|
||||||
|
this.emit('fail', { device: destination.device.device, error })
|
||||||
|
}
|
||||||
this.emit('error', error)
|
this.emit('error', error)
|
||||||
})
|
})
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user