-
Notifications
You must be signed in to change notification settings - Fork 162
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
relicensing: Rewrite PR "DevicePathToText and DevicePathFromText Protocol" #1528
base: main
Are you sure you want to change the base?
Conversation
#[derive(Clone, Copy, Debug)] | ||
pub struct AllowShortcuts(pub bool); | ||
|
||
/// Wrapper for a string internally allocated from | ||
/// UEFI boot services memory. | ||
/// UCS-2 string allocated from UEFI pool memory. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
General question: Why do we have this type? I think, this can also be a CString16
?
Do we at least want to write how it differs from CString16?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Updated the docstring to clarify. Since this is allocated internally by UEFI, we'd have to do a second memory allocation to copy it to a CString16
. (Or alternatively, the CString16
type could be modified to contain either a Vec
or a pool allocation, and switch out how it's dropped at the end, but that's probably more complicated than it's worth.) I'm not necessarily opposed to doing something else here, like just accept an extra memory copy, but should probably think about that as part of #1303 since CString16
requires the alloc
feature.
6f92baa
to
eb0849f
Compare
eb0849f
to
1f52a31
Compare
See #1521. This rewrites code from supdrewin that we do not have relicensing approval for.
Checklist