return None
# note that we got one
- # TODO: we should log this crap somewhere
- print "Connection from", address
+ muffmisc.log("Connection from " + address[0])
# disable blocking so we can proceed whether or not we can send/receive
connection.setblocking(0)
newsocket.listen(1)
# note that we're now ready for user connections
- # TODO: we should log this crap somewhere
- print "Waiting for connection(s)..."
+ muffmisc.log("Waiting for connection(s)...")
# store this in a globally-accessible place
muffvars.newsocket = newsocket
"""Go through all connected users and close their sockets."""
# note that we're closing all sockets
- # TODO: we should log this crap somewhere
- print "Closing remaining connections..."
+ muffmisc.log("Closing remaining connections...")
# iterate over each connected user and close their associated sockets
for user in muffvars.userlist: