Fix: address multiple minor bugs found during code audit#492
Fix: address multiple minor bugs found during code audit#492vinayakjeet wants to merge 1 commit intourunc-dev:mainfrom
Conversation
✅ Deploy Preview for urunc ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
|
hi @cmainas can you please review the changes . |
IrvingMg
left a comment
There was a problem hiding this comment.
Some changes need to be reviewed, as they’re breaking unit tests and may not be actual bugs. You can run make unittest to verify that they pass.
ca7884f to
12bd835
Compare
|
Changes look ok, but just a question. Where does "consoleFile nil-deref" take place? |
|
@cmainas |
Yes, that is correct. |
12bd835 to
f754079
Compare
|
Hi @cmainas — I’ve rebased the PR onto the latest |
|
Thank you @vinayakjeet , please rebase once more to be on the safe side. |
f754079 to
49a8488
Compare
|
@cmainas rebased and updated — it's good to go now. Thanks |
- Use annotHypervisor instead of annotType in isRunning() - Remove nil error wrapping in run.go - Fix potential nil-deref on consoleFile in rootfs.go - Use errors.Is() for sentinel error comparison - Propagate errors in getInitPid instead of swallowing - Propagate error in deleteAllTCFilters Signed-off-by: vinayakjeet <vinayakjeetog@gmail.com>
Description
Refactor error handling and nil-safety: use annotHypervisor in isRunning, remove nil error wrapping, fix consoleFile nil-deref, use errors.Is for sentinel checks, and propagate errors from getInitPid and deleteAllTCFilters.
Related issues
None
How was this tested?
lint and build
LLM usage
None
Checklist
make lint).make test_ctr,make test_nerdctl,make test_docker,make test_crictl).