Problem with http download

Hello,

I am trying to download file through httpclient:

http://www.panda3d.org/manual/index.php/Downloading_a_File

But When writing in file:

fileHandle = open ( self.directory +  self.files[self.iterFile], 'w' ) 
						fileHandle.write(self.rf.getData())
						fileHandle.close()

But in the files, I have new blank lines into the file.

Have I done something wrong?

On that manual page there’s code that waits for the file to finish downloading. Are you doing that?