commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Fabio Cuomo" <>
Subject Please Help me !! listFiles() return null
Date Wed, 24 Mar 2004 11:16:05 GMT
i use FTP connection under WinXP, using default windows FTP server..for 
now..after it will work under linux system...i've done some debug on code, 
and when i execute

                                    FTPFile[] filelist = ftp.listFiles();

i get a null pointer exception..Stack trace inform me only of null pointer 
exception, other lines tell me where error happens, however i attach it :
	at test.ftp.MainClass.check(
	at test.ftp.MainClass.<init>(
	at test.ftp.MainClass.main(

This is my scenario: i have an application that check into database for a 
value. After this check i establish an FTP connection to localhost FTP after 
the connection and login i get follow reply message :
                       Reply is : 230 User mulp logged in.

As already said i use listNames() function, but it is a bit useful , however 
reply code after listNames() is :
                       Reply is : 226 Transfer complete
after i get list of names in ftp root.

When i execute FTPFile[] filelist = ftp.listFiles(); i get as reply message 

                       Reply is : 226 Transfer complete.

it seems all ok but return value is null and then i get a null pointer 
exception while i want to extract information about files.
listFiles() return value is null and not a single entry of FTPFile[].

Please help me i'm in trouble..Any kind of help is granted.

Thanx in advance.
regards mulp

Filtri antispamming e antivirus per la tua casella di posta

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message