send file of size 0 with FTP on AIX

I'm using IBM AIX 5.2 to send file with ftp to other unix machine.
The command is into a shell:
...
ftp -n > outFtp 2> errFtp <<PARAM
open $2
user $3 $4
put $1 $remote
bye
PARAM
...

then i look at the size of errFtp and outFtp to see if there are some error message.
It works with file of size > 0.
It doesn't works with file of size 0 cose the server return in the standard error (>errFtp) a message like this:
netout: write returned 0?

It's possible to configure server messaging to skip this kind of "warning"?
Other method to check if ftp works fine?

Thanks.

In your script check the file size before you get to ftp:

let size=`wc -c $myfilename`
if [ $size .gt. 0 ]; then
..... ftp....

fi 

Thanks, but i have to send the file, also if the size is 0.

works fine on Solaris - must be AIX [???] server related

yes, i'm porting an application from Solaris 5.8 to AIX 5.2 and i've found the problem.