Expose vendor defined error code#300
Merged
Merged
Conversation
74a094b to
14aa761
Compare
hug-dev
previously approved these changes
Jul 22, 2025
14aa761 to
ad31c96
Compare
Contributor
Author
|
On second thought, I additionally added (in a separate commit) an additional enum value for unknown error codes. This way, when the error code is neither standardised nor from the vendor-reserved area, at least the error code gets bubbled up to the calling application. Mapping it to Let me know what you think, I can amend or drop this. |
ad31c96 to
7a78363
Compare
Jakuje
reviewed
Jul 22, 2025
CK_ULONG is a type alias for std::os::raw::c_ulong. c_ulong is always either u32 or u64: - https://doc.rust-lang.org/std/os/raw/type.c_ulong.html - https://github.com/rust-lang/rust/blob/master/library/core/src/ffi/primitives.rs And in the end, it will do the same thing anyway: https://github.com/rust-lang/rust/blob/0162cc5/library/core/src/num/uint_macros.rs#L45 Signed-off-by: Thore Goebel <git@thore.io>
Fixes parallaxsecond#299 Signed-off-by: Thore Goebel <git@thore.io>
This makes debugging easier, since the error code is readily available. Signed-off-by: Thore Goebel <git@thore.io>
7a78363 to
fabf938
Compare
hug-dev
approved these changes
Jul 23, 2025
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #299
Tested with:
This contribution is in personal capacity.