tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Alexandre Rojkov <alexandre.roj...@mobileq.com>
Subject bug?
Date Fri, 16 Feb 2001 01:35:27 GMT
Hi all

I have a servlet which does following in doPost method:

	String bufferFormData = request.getReader().readLine();

the servlet hangs in the readLine

following code gives me only one character from the request content:

	int nLen = req.getContentLength();
	if(nLen > 0)
	{
		byte b[] = new byte[nLen];				
		int nCount = 0;				
		for(int i = 0; i < nLen; i++)
		{
			 int nChar = req.getReader().read();
			 if(nChar == -1)
				break;
			 b[i] = (byte)nChar;
			 nCount++;
		}
	}

Both versions work on IPlanet

Any ideas?

Thanks

Alex

Mime
View raw message