summaryrefslogtreecommitdiffstats
path: root/AirPlayService.py
diff options
context:
space:
mode:
Diffstat (limited to 'AirPlayService.py')
-rw-r--r--AirPlayService.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/AirPlayService.py b/AirPlayService.py
index 5b4e58c..925b4e0 100644
--- a/AirPlayService.py
+++ b/AirPlayService.py
@@ -126,7 +126,7 @@ class AirPlayProtocolHandler(asyncore.dispatcher_with_send):
126 if(answer is not ""): 126 if(answer is not ""):
127 self.send(answer) 127 self.send(answer)
128 128
129 def getDateTime(self): 129 def get_datetime(self):
130 today = datetime.now() 130 today = datetime.now()
131 datestr = today.strftime("%a, %d %b %Y %H:%M:%S") 131 datestr = today.strftime("%a, %d %b %Y %H:%M:%S")
132 return datestr+" GMT" 132 return datestr+" GMT"
@@ -141,7 +141,7 @@ class AirPlayProtocolHandler(asyncore.dispatcher_with_send):
141 answer = "HTTP/1.1 101 Switching Protocols" 141 answer = "HTTP/1.1 101 Switching Protocols"
142 answer += "\nUpgrade: PTTH/1.0" 142 answer += "\nUpgrade: PTTH/1.0"
143 answer += "\nConnection: Upgrade" 143 answer += "\nConnection: Upgrade"
144 answer += "\nDate: " + self.getDateTime() 144 answer += "\nDate: " + self.get_datetime()
145 answer += "\nContent-Length: " + str(clength) 145 answer += "\nContent-Length: " + str(clength)
146 if (header != ""): 146 if (header != ""):
147 answer += "\n" + header 147 answer += "\n" + header