Skip to content
This repository has been archived by the owner on Feb 4, 2019. It is now read-only.

Commit

Permalink
Merge pull request #18 from deniak/master
Browse files Browse the repository at this point in the history
python no longer support headers with a colon
  • Loading branch information
dontcallmedom committed Jun 22, 2016
2 parents 4dacd0a + de4ec88 commit 564457b
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions webidl-check
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ def copyHeader(copy_func, source, key, header_name=None):
return False
elif header_name is None:
header_name = key
copy_func("%s: %s" % (header_name, value))
copy_func(header_name, value)
return True

def setupRequest(source_headers):
Expand Down Expand Up @@ -127,7 +127,7 @@ def serveRequest():
except WrongConfigurationException,e:
printError(output,doc, textoutputselected, "Could not run widlproc", str(e))
for header_name in ('Last-Modified', 'Expires'):
if copyHeader(sys.stdout.write, srcheaders, header_name):
if copyHeader(lambda header, value: sys.stdout.write("%s: %s" %(header, value)), srcheaders, header_name):
print
title = srcheaders.get('title', title)
elif inp:
Expand Down

0 comments on commit 564457b

Please sign in to comment.