mirror of
https://gitlab.com/apparmor/apparmor
synced 2025-08-22 01:57:43 +00:00
logprof/genprof and related utilities in python. Because the branch that was worked on was not based on the apparmor tree, not all of the history can be maintained for files that are not newly created or entirely rewritten in the branch. (This merge also includes a subsequent commit to the branch I was merging from which includes my missed bzr add of utils/apparmor/translations.py)
22 lines
693 B
Python
22 lines
693 B
Python
# ------------------------------------------------------------------
|
|
#
|
|
# Copyright (C) 2014 Canonical Ltd.
|
|
#
|
|
# This program is free software; you can redistribute it and/or
|
|
# modify it under the terms of version 2 of the GNU General Public
|
|
# License published by the Free Software Foundation.
|
|
#
|
|
# ------------------------------------------------------------------
|
|
import gettext
|
|
|
|
TRANSLATION_DOMAIN = 'apparmor-utils'
|
|
|
|
__apparmor_gettext__ = None
|
|
|
|
def init_translation():
|
|
global __apparmor_gettext__
|
|
if __apparmor_gettext__ is None:
|
|
t = gettext.translation(TRANSLATION_DOMAIN, fallback=True)
|
|
__apparmor_gettext__ = t.gettext
|
|
return __apparmor_gettext__
|