mirror of
https://github.com/rwinkhart/cmutton.git
synced 2026-08-27 20:36:31 -04:00
Free input privKeyPascal
This commit is contained in:
+4
-3
@@ -9,9 +9,10 @@ import (
|
|||||||
"github.com/rwinkhart/libmutton/privkey"
|
"github.com/rwinkhart/libmutton/privkey"
|
||||||
)
|
)
|
||||||
|
|
||||||
// SetPrivKeyBytes forces libmutton to use custom bytes for the SSH private key.
|
// SetPrivKeyBytesAndFree forces libmutton to use custom bytes for the SSH private key.
|
||||||
//
|
//
|
||||||
//export SetPrivKeyBytes
|
//export SetPrivKeyBytesAndFree
|
||||||
func SetPrivKeyBytes(privKeyPascal C.PascalString) {
|
func SetPrivKeyBytesAndFree(privKeyPascal C.PascalString) {
|
||||||
privkey.SetBytes(C.GoBytes(unsafe.Pointer(privKeyPascal.data), privKeyPascal.len))
|
privkey.SetBytes(C.GoBytes(unsafe.Pointer(privKeyPascal.data), privKeyPascal.len))
|
||||||
|
FreePascalString(privKeyPascal)
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user