File: _base.py

package info (click to toggle)
olm 2.2.2%2Bgit20170526.0fd768e%2Bdfsg-1
  • links: PTS
  • area: main
  • in suites: buster
  • size: 2,040 kB
  • ctags: 1,713
  • sloc: ansic: 10,149; cpp: 7,345; java: 2,540; objc: 1,341; python: 1,205; makefile: 236; sh: 160; xml: 10; asm: 7
file content (18 lines) | stat: -rw-r--r-- 289 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
import os.path
import sysconfig

from ctypes import *


lib = cdll.LoadLibrary(os.path.join(
    "/usr/lib", sysconfig.get_config_var('MULTIARCH'), "libolm.so.2")
)

lib.olm_error.argtypes = []
lib.olm_error.restypes = c_size_t

ERR = lib.olm_error()


class OlmError(Exception):
    pass