Skip to content

Fix incorrect trim of socket address prefix#113

Open
dmcgowan wants to merge 1 commit intocontainerd:mainfrom
dmcgowan:fix-socket-parent-create
Open

Fix incorrect trim of socket address prefix#113
dmcgowan wants to merge 1 commit intocontainerd:mainfrom
dmcgowan:fix-socket-parent-create

Conversation

@dmcgowan
Copy link
Member

Arguments are backwards

Signed-off-by: Derek McGowan <derek@mcg.dev>
Copilot AI review requested due to automatic review settings March 14, 2026 00:54
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Fixes creation of the shim socket’s parent directory on Unix by correctly stripping the unix:// scheme and deriving the directory path (instead of incorrectly trimming and taking the basename).

Changes:

  • Correct strings.TrimPrefix argument order when removing unix:// from the socket address.
  • Use filepath.Dir(...) (parent directory) rather than filepath.Base(...) (final path element) before calling os.MkdirAll.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

You can also share your feedback on Copilot code review. Take the survey.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants