Skip to content

Commit 588bd00

Browse files
committed
add new error codes for save, restore, network block device, and USB device errors
1 parent 179f6bb commit 588bd00

File tree

2 files changed

+59
-3
lines changed

2 files changed

+59
-3
lines changed

errorcode_string.go

Lines changed: 21 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

vzerror.go

Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,14 @@ const (
4343
// ErrorNotSupported represents the operation is not supported.
4444
// Available from macOS 13.0 and above.
4545
ErrorNotSupported
46+
47+
// ErrorSave represents the save operation failed.
48+
// Available from macOS 14.0 and above.
49+
ErrorSave
50+
51+
// ErrorRestore represents the restore operation failed.
52+
// Available from macOS 14.0 and above.
53+
ErrorRestore
4654
)
4755

4856
/* macOS installation errors. */
@@ -75,3 +83,33 @@ const (
7583
// Available from macOS 13.0 and above.
7684
ErrorInstallationFailed
7785
)
86+
87+
/* Network Block Device errors. */
88+
const (
89+
// ErrorNetworkBlockDeviceNegotiationFailed represents the connection or the negotiation with the NBD server failed.
90+
// Available from macOS 14.0 and above.
91+
ErrorNetworkBlockDeviceNegotiationFailed ErrorCode = 20001 + iota
92+
93+
// ErrorNetworkBlockDeviceDisconnected represents the NBD client is disconnected from the server.
94+
// Available from macOS 14.0 and above.
95+
ErrorNetworkBlockDeviceDisconnected
96+
)
97+
98+
/* USB device hot-plug errors. */
99+
const (
100+
// ErrorUSBControllerNotFound represents controller not found.
101+
// Available from macOS 15.0 and above.
102+
ErrorUSBControllerNotFound ErrorCode = 30001 + iota
103+
104+
// ErrorDeviceAlreadyAttached represents Device is already attached.
105+
// Available from macOS 15.0 and above.
106+
ErrorDeviceAlreadyAttached
107+
108+
// ErrorDeviceInitializationFailure represents device initialization failure.
109+
// Available from macOS 15.0 and above.
110+
ErrorDeviceInitializationFailure
111+
112+
// ErrorDeviceNotFound represents device not found.
113+
// Available from macOS 15.0 and above.
114+
ErrorDeviceNotFound
115+
)

0 commit comments

Comments
 (0)