2
0
mirror of https://github.com/xcat2/xcat-core.git synced 2025-08-22 19:20:24 +00:00

Make variable output byte instead of string

This commit is contained in:
GONG Jie
2019-03-21 16:03:12 +08:00
parent d4715d2745
commit 58441c8489

View File

@@ -116,8 +116,8 @@ try:
#UNCOMMENTOENABLEDEBUGPORT# newcommand = b""
#UNCOMMENTOENABLEDEBUGPORT# for i in command[1:]:
#UNCOMMENTOENABLEDEBUGPORT# newcommand = newcommand + i + b" "
#UNCOMMENTOENABLEDEBUGPORT# output = os.popen(newcommand.decode('utf-8')).read()
#UNCOMMENTOENABLEDEBUGPORT# newSocket.send(output.encode())
#UNCOMMENTOENABLEDEBUGPORT# output = os.popen(newcommand.decode('utf-8')).read().encode()
#UNCOMMENTOENABLEDEBUGPORT# newSocket.send(output)
#UNCOMMENTOENABLEDEBUGPORT# break
if(command[0] == b"screendump"):
newcommand = "cat /dev/vcs"