You get a new message every time you call content.recv(). That's one for the print statement and another for the if clause. Read the message into a local variable instead. As a side note, use '==', not 'is' for the compare.
while True:
msg = content.recv()
print msg
if msg == "0":
sys.exit()