Commit b4c4e01f authored by Canek Peláez's avatar Canek Peláez
Browse files

games-misc/ds4drv: Use ConfigParser.

parent 84e53ef3
Loading
Loading
Loading
Loading
+5 −1
Original line number Diff line number Diff line
# Copyright 1999-2024 Gentoo Authors
# Copyright 1999-2025 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2

EAPI="8"
@@ -26,6 +26,10 @@ DEPEND="
"
RDEPEND="${DEPEND}"

PATCHES=(
	"${FILESDIR}/ds4drv-config-parser.patch"
)

src_install() {
	distutils-r1_src_install
	systemd_dounit "${S}"/systemd/ds4drv.service
+22 −0
Original line number Diff line number Diff line
diff --git a/ds4drv/config.py b/ds4drv/config.py
index d01a791..c0f61d1 100644
--- a/ds4drv/config.py
+++ b/ds4drv/config.py
@@ -69,7 +69,7 @@ daemonopt.add_argument("--daemon-pid", default=DAEMON_PID_FILE, metavar="file",
 controllopt = parser.add_argument_group("controller options")
 
 
-class Config(configparser.SafeConfigParser):
+class Config(configparser.ConfigParser):
     def load(self, filename):
         self.read([filename])
 
@@ -96,7 +96,7 @@ class Config(configparser.SafeConfigParser):
             return {}
 
     def sections(self, prefix=None):
-        for section in configparser.SafeConfigParser.sections(self):
+        for section in configparser.ConfigParser.sections(self):
             match = re.match(r"{0}:(.+)".format(prefix), section)
             if match:
                 yield match.group(1), section