From: Steven Black Date: Sun, 13 Mar 2016 15:24:17 +0000 (-0400) Subject: Fixes #102. X-Git-Url: http://git.99rst.org/?a=commitdiff_plain;h=31ea0fc25b0c3095864d186d1d42f4d94ca4794a;p=stevenblack-hosts.git Fixes #102. --- diff --git a/updateHostsFile.py b/updateHostsFile.py index eca6e83fa..15de680e8 100644 --- a/updateHostsFile.py +++ b/updateHostsFile.py @@ -292,7 +292,7 @@ def removeDupsAndExcl(mergeFile): os.makedirs(outputPath) # Another mode is required to read and write the file in Python 3 - finalFile = open(os.path.join(outputPath, 'hosts'), 'w+') + finalFile = open(os.path.join(outputPath, 'hosts'), 'r+') mergeFile.seek(0) # reset file pointer hostnames = set()