Advertisement
aveyo

dota2bandwidthsaver_undo

Apr 5th, 2016
864
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Batch 0.59 KB | None | 0 0
  1. :: dota2bandwidthsaver_undo by aveyo v1.0 - run as administrator!
  2. @ECHO OFF &SETLOCAL ENABLEDELAYEDEXPANSION
  3.  
  4. ECHO. &ECHO   PLEASE WAIT...
  5.  
  6. SET "h=%WINDIR%\System32\drivers\etc\hosts"
  7. IF NOT EXIST "%h%.d2bws" EXIT /B
  8. :: get rights and restore backup
  9. TAKEOWN /F "%h%" >nul 2>&1
  10. ICACLS "%h%" /reset /T /Q >nul 2>&1
  11. ATTRIB -R "%h%" >nul 2>&1
  12. COPY /Y "%h%.d2bws" "%h%" >nul 2>&1
  13. DEL /F /Q "%h%.d2bws" >nul 2>&1
  14. ATTRIB +R "%h%" >nul 2>&1
  15. :: reset network stack
  16. NBTSTAT -R >nul 2>&1
  17. IPCONFIG /flushdns >nul 2>&1
  18. NET STOP dnscache >nul 2>&1
  19. NET START dnscache >nul 2>&1
  20.  
  21. ENDLOCAL
  22. EXIT /B
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement