Skip to content
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

v1.6.3 #241

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
4 changes: 2 additions & 2 deletions BuildTools/Package.resolved
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@
"repositoryURL": "https://github.com/nicklockwood/SwiftFormat",
"state": {
"branch": null,
"revision": "872e7034f54aeee3f20acf790ecc13e1383f7360",
"version": "0.48.4"
"revision": "415c08ce2d63ff8bca95228939c92375882ea538",
"version": "0.49.2"
}
}
]
Expand Down
2 changes: 1 addition & 1 deletion BuildTools/Package.swift
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ let package = Package(
name: "BuildTools",
platforms: [.macOS(.v10_11)],
dependencies: [
.package(url: "https://github.com/nicklockwood/SwiftFormat", from: "0.48.4"),
.package(url: "https://github.com/nicklockwood/SwiftFormat", from: "0.49.2"),
],
targets: [.target(name: "BuildTools", path: "")]
)
4 changes: 3 additions & 1 deletion eul.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -1181,7 +1181,7 @@
isa = PBXProject;
attributes = {
LastSwiftUpdateCheck = 1240;
LastUpgradeCheck = 1220;
LastUpgradeCheck = 1320;
ORGANIZATIONNAME = "Gao Sun";
TargetAttributes = {
6C2688ED2556762B00FB7306 = {
Expand Down Expand Up @@ -2106,6 +2106,7 @@
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor;
CODE_SIGN_ENTITLEMENTS = SelfUpdate/SelfUpdate.entitlements;
CODE_SIGN_IDENTITY = "-";
CODE_SIGN_STYLE = Automatic;
COMBINE_HIDPI_IMAGES = YES;
DEVELOPMENT_ASSET_PATHS = "\"SelfUpdate/Preview Content\"";
Expand All @@ -2130,6 +2131,7 @@
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor;
CODE_SIGN_ENTITLEMENTS = SelfUpdate/SelfUpdate.entitlements;
CODE_SIGN_IDENTITY = "-";
CODE_SIGN_STYLE = Automatic;
COMBINE_HIDPI_IMAGES = YES;
DEVELOPMENT_ASSET_PATHS = "\"SelfUpdate/Preview Content\"";
Expand Down
2 changes: 1 addition & 1 deletion eul.xcodeproj/xcshareddata/xcschemes/eul.xcscheme
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "1220"
LastUpgradeVersion = "1320"
version = "1.3">
<BuildAction
parallelizeBuildables = "YES"
Expand Down
7 changes: 6 additions & 1 deletion eul/Utilities/SMC.swift
Original file line number Diff line number Diff line change
Expand Up @@ -296,6 +296,9 @@ public enum SMCKit {
/// - parameter kIOReturn: I/O Kit error code
/// - parameter SMCResult: SMC specific return code
case unknown(kIOReturn: kern_return_t, SMCResult: UInt8)

/// SMCParamStruct size is not desired
case paramStructSizeMismatched
}

/// Connection to the SMC driver
Expand Down Expand Up @@ -380,7 +383,9 @@ public enum SMCKit {
selector: SMCParamStruct.Selector = .kSMCHandleYPCEvent)
throws -> SMCParamStruct
{
assert(MemoryLayout<SMCParamStruct>.stride == 80, "SMCParamStruct size is != 80")
guard MemoryLayout<SMCParamStruct>.stride == 80 else {
throw SMCError.paramStructSizeMismatched
}
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Нормально, кати


var outputStruct = SMCParamStruct()
let inputStructSize = MemoryLayout<SMCParamStruct>.stride
Expand Down