DemesneGH commented on code in PR #179: URL: https://github.com/apache/incubator-teaclave-trustzone-sdk/pull/179#discussion_r2046496148
########## optee-teec/src/context.rs: ########## @@ -57,11 +57,7 @@ impl Context { /// ``` pub fn new() -> Result<Context> { // define an empty TEEC_Context - let mut raw_ctx = raw::TEEC_Context { - fd: 0, - reg_mem: false, - memref_null: false, - }; + let mut raw_ctx = unsafe { std::mem::zeroed() }; Review Comment: Since usage of `unsafe()` would need a explanation when we enable `cargo clippy` in the future. I think we need to unify the unsafe usage. Will all similar initializations use `unsafe { std::mem::zeroed() }` or just fill in default values? What's your opinion on it? -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: dev-unsubscr...@teaclave.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscr...@teaclave.apache.org For additional commands, e-mail: dev-h...@teaclave.apache.org