File howdy-use-correct-python-exec.patch of Package howdy

---
 src/pam.py |    5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

Index: howdy-2.6.1/src/pam.py
===================================================================
--- howdy-2.6.1.orig/src/pam.py
+++ howdy-2.6.1/src/pam.py
@@ -5,6 +5,7 @@ import subprocess
 import os
 import glob
 import syslog
+from sys import version_info
 
 # pam-python is running python 2, so we use the old module here
 import configparser
@@ -41,7 +42,9 @@ def doAuth(pamh):
 	syslog.syslog(syslog.LOG_INFO, "Attempting facial authentication for user " + pamh.get_user())
 
 	# Run compare as python3 subprocess to circumvent python version and import issues
-	status = subprocess.call(["/usr/bin/python3", os.path.dirname(os.path.abspath(__file__)) + "/compare.py", pamh.get_user()])
+	status = subprocess.call([f'/usr/bin/python{version_info.major}.{version_info.minor}',
+						   os.path.dirname(os.path.abspath(__file__)) + "/compare.py",
+						   pamh.get_user()])
 
 	# Status 10 means we couldn't find any face models
 	if status == 10:
openSUSE Build Service is sponsored by