]> Devi Nivas Git - chevron.git/commitdiff
mmap does not actually work like that.
authorDaniel Morrison <dan@morrison.ph>
Sun, 16 Nov 2014 05:17:14 +0000 (00:17 -0500)
committerDaniel Morrison <dan@morrison.ph>
Sun, 16 Nov 2014 05:35:06 +0000 (00:35 -0500)
- Remove mmap
- Just load the entire file into memory (should be fine)

entei.py

index 6da899d3613c0d708cfcb08974d9bc5f1e2b469c..6f01976593d1e106aa245e5c7ed4038f632cc6b1 100755 (executable)
--- a/entei.py
+++ b/entei.py
@@ -2,7 +2,6 @@
 
 import json
 
-import mmap
 from sys import argv
 
 
@@ -47,7 +46,7 @@ def tokenize(template):
     }
 
     try:
-        mmap.mmap(template.fileno())
+        template = template.read()
     except AttributeError:
         pass