func checkError() error { c := C.libvlc_errmsg() if c != nil { return errors.New(C.GoString(c)) } return nil }
// checkError checks if there is a new error message available. If so, return // it as an os.Error. For internal use only. func checkError() (err error) { if c := C.libvlc_errmsg(); c != nil { err = errors.New(C.GoString(c)) C.free(unsafe.Pointer(c)) } return }
func getError() error { msg := C.libvlc_errmsg() if msg != nil { return errors.New(C.GoString(msg)) } return nil }
func LastError() error { str := C.libvlc_errmsg() if str == nil { return nil } defer C.free(unsafe.Pointer(str)) defer C.libvlc_clearerr() return errors.New(C.GoString(str)) }