1
0
mirror of https://github.com/samba-team/samba.git synced 2025-12-17 04:23:50 +03:00

python: do not always import socket_server

This cost around 10ms for every Python script, and was only used in one
test.

Signed-off-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
This commit is contained in:
Douglas Bagnall
2020-05-26 11:33:42 +12:00
committed by Andrew Bartlett
parent 5c06ab8338
commit 2323ea6f07
2 changed files with 1 additions and 4 deletions

View File

@@ -70,7 +70,6 @@ if PY3:
return (x > y) - (x < y)
# compat functions
from functools import cmp_to_key as cmp_to_key_fn
import socketserver as SocketServer
# compat types
integer_types = int,
@@ -145,8 +144,6 @@ else:
return K
else:
from functools import cmp_to_key as cmp_to_key_fn
# compat functions
import SocketServer as SocketServer
# compat types
integer_types = (int, long)