No subject

Rahul Sircar devilsgrin94 at gmail.com
Sat Jul 22 15:39:58 EDT 2017


I wrote my code for downloading a file 'Metasploitable' using urllib2.But
it seems to have entered infinite loop.Because the screen is blank.It just
hangs there.Please have a look at my code.

import urllib2
file = 'metasploitable-linux-2.0.0.zip'
url='
https://downloads.sourceforge.net/project/metasploitable/Metasploitable2/metasploitable-linux-2.0.0.zip
'
response = urllib2.urlopen(url)
fh=open(file,'w')
fh.write(response.read())
fh.close()



More information about the Python-list mailing list