File: util.go

package info (click to toggle)
golang-github-jochenvg-go-udev 0.0~git20171110.d6b62d5-2
  • links: PTS, VCS
  • area: main
  • in suites: bookworm, bookworm-backports
  • size: 144 kB
  • sloc: makefile: 4
file content (18 lines) | stat: -rw-r--r-- 251 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
// +build linux,cgo

package udev

/*
  #cgo LDFLAGS: -ludev
  #include <libudev.h>
  #include <linux/types.h>
  #include <stdlib.h>
	#include <linux/kdev_t.h>
*/
import "C"

import "unsafe"

func freeCharPtr(s *C.char) {
	C.free(unsafe.Pointer(s))
}