Skip to content

Commit

Permalink
Merge pull request #713 from sananya12/nvsandboxutils-sananya
Browse files Browse the repository at this point in the history
Fix an incompatible pointer conversion in nvsandboxutils
  • Loading branch information
elezar authored Sep 26, 2024
2 parents 0e68f60 + 906531f commit 79c59ae
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion internal/nvsandboxutils/gpu-resources.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ package nvsandboxutils

import (
"strings"
"unsafe"
)

import "C"
Expand Down Expand Up @@ -54,7 +55,7 @@ func (l *library) GetGpuResource(uuid string) ([]GpuFileInfo, Ret) {
var fileInfos []GpuFileInfo
for fileInfo := request.Files; fileInfo != nil; fileInfo = fileInfo.Next {
fi := GpuFileInfo{
Path: C.GoString((*C.char)(fileInfo.FilePath)),
Path: C.GoString((*C.char)(unsafe.Pointer(fileInfo.FilePath))),
Type: FileType(fileInfo.FileType),
SubType: FileSystemSubType(fileInfo.FileSubType),
Module: FileModule(fileInfo.Module),
Expand Down

0 comments on commit 79c59ae

Please sign in to comment.