🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.cppbuilder.internet.socket
Article #22

Re: urgent-help on indy

#22
From: Remy Lebeau (TeamB)
Date: Tue, 29 Jul 2008 19:35
35 lines
2359 bytes
"sa" <shaikakbar250281@yahoo.co.in> wrote in message 
news:488f6705@newsgroups.borland.com...

>          FILEStream->SaveToFile("C:\\test.xml");

Since you are downloading different types of files, you should use the 
filename that the server sends back to you in the reply headers.

> AcceptEncoding = gzip, deflate

Indy 9 does not support those.  You should not be specifying them in your 
request header unless you are planning on decompressing the data manually if 
the server compresses it.  Otherwise, upgrade to Indy 10, which has a new 
Compressor property in TIdHTTP to handle that.

> With the same code and same request headers the program works
> fine with DSL and Dialup connection. But failed with USB wireless
> internet connection. Failed in the sense, after download xml file i see
> junk characters in the file

The data is likely being compressed by the server, since your request 
headers are saying that compression is allowed.

> Browser can able to display the files

The browser is decompressing the data.

> i compared headers using HTTP packet sniffer but no luck.

Does the "Content-Transfer-Encoding" reply header include "gzip" or 
"deflate" in it?  If so, then the data is compressed.


Gambit 
Technical Details
Message-ID: <488f7459$1@newsgroups.borland.com>
Path: arc1-ca.pugleaf.net!g2news2.google.com!news3.google.com!feeder3.cambrium.nl!feed.tweaknews.nl!2001:4de0:1::3.MISMATCH!ramfeed2.eweka.nl!eweka.nl!lightspeed.eweka.nl!195.114.231.41.MISMATCH!feeder.news-service.com!newsfeed.freenet.de!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail
References: <488f6705@newsgroups.borland.com>

Show Full Headers
Complete Article Headers
X-Google-Thread: 11508e,3402e2c45f39c911
X-Google-Attributes: gid11508e,domainid0,public,usenet
X-Google-Language: ENGLISH,ASCII-7-bit
From: "Remy Lebeau \(TeamB\)" <no.spam@no.spam.com>
Newsgroups: borland.public.cppbuilder.internet.socket
References: <488f6705@newsgroups.borland.com>
Subject: Re: urgent-help on indy
Date: Tue, 29 Jul 2008 12:35:02 -0700
Lines: 37
Organization: Lebeau Software
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2900.3138
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.3198
X-RFC2646: Format=Flowed; Response
NNTP-Posting-Host: 207.178.157.90
Message-ID: <488f7459$1@newsgroups.borland.com>
X-Trace: newsgroups.borland.com 1217360985 207.178.157.90 (29 Jul 2008 12:49:45 -0700)
Path: arc1-ca.pugleaf.net!g2news2.google.com!news3.google.com!feeder3.cambrium.nl!feed.tweaknews.nl!2001:4de0:1::3.MISMATCH!ramfeed2.eweka.nl!eweka.nl!lightspeed.eweka.nl!195.114.231.41.MISMATCH!feeder.news-service.com!newsfeed.freenet.de!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail