From 31ea0fc25b0c3095864d186d1d42f4d94ca4794a Mon Sep 17 00:00:00 2001 From: Steven Black Date: Sun, 13 Mar 2016 11:24:17 -0400 Subject: [PATCH] Fixes #102. --- updateHostsFile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) 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()