Skip to content

fixed compile issue on macOS 12 #171

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Nov 5, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions virtualization_14.h
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,10 @@ void *newVZNVMExpressControllerDeviceConfiguration(void *attachment);
void *newVZDiskBlockDeviceStorageDeviceAttachment(int fileDescriptor, bool readOnly, int syncMode, void **error);
void *newVZNetworkBlockDeviceStorageDeviceAttachment(const char *url, double timeout, bool forcedReadOnly, int syncMode, void **error, uintptr_t cgoHandle);

#ifdef INCLUDE_TARGET_OSX_14
@interface VZNetworkBlockDeviceStorageDeviceAttachmentDelegateImpl : NSObject <VZNetworkBlockDeviceStorageDeviceAttachmentDelegate>
- (instancetype)initWithHandle:(uintptr_t)cgoHandle;
- (void)attachment:(VZNetworkBlockDeviceStorageDeviceAttachment *)attachment didEncounterError:(NSError *)error API_AVAILABLE(macos(14.0));
- (void)attachmentWasConnected:(VZNetworkBlockDeviceStorageDeviceAttachment *)attachment API_AVAILABLE(macos(14.0));
@end
#endif
2 changes: 2 additions & 0 deletions virtualization_14.m
Original file line number Diff line number Diff line change
Expand Up @@ -91,6 +91,7 @@
RAISE_UNSUPPORTED_MACOS_EXCEPTION();
}

#ifdef INCLUDE_TARGET_OSX_14
@implementation VZNetworkBlockDeviceStorageDeviceAttachmentDelegateImpl {
uintptr_t _cgoHandle;
}
Expand All @@ -112,3 +113,4 @@ - (void)attachmentWasConnected:(VZNetworkBlockDeviceStorageDeviceAttachment *)at
attachmentWasConnectedHandler(_cgoHandle);
}
@end
#endif
Loading