Skip to content

Commit

Permalink
Wrap sodium/version
Browse files Browse the repository at this point in the history
  • Loading branch information
silkeh committed Apr 29, 2017
1 parent 52a0339 commit b513b79
Showing 1 changed file with 18 additions and 0 deletions.
18 changes: 18 additions & 0 deletions sodium/version.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
package sodium

// #cgo pkg-config: libsodium
// #include <stdlib.h>
// #include <sodium.h>
import "C"

func SodiumVersionString() string {
return C.GoString(C.sodium_version_string())
}

func SodiumLibaryVersionMajor() int {
return int(C.sodium_library_version_major())
}

func SodiumLibaryVersionMinor() int {
return int(C.sodium_library_version_minor())
}

0 comments on commit b513b79

Please sign in to comment.