[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

HTTPAPI - EXAMPLE1 - Send returns error #55



   Hello,

   I am just beginning to test HTTPAPI on our system.  I'm hoping to use
   it in some development.  So THANK YOU for this utility (also for the
   JDBC which is working great!).

   However, I am not getting off to a great start as I am getting an error
   with the EXAMPLE1 program.  I modified it to pick up a PDF from IBM
   just to get another sample but the results are the same as when I try
   to download from scottklement.com.  I put the HTTPAPIR4 service program
   in debug to track it down and it is  where the do_oper procedure calls
   SendReq.  It is on the second call with CRLF in the buffer :


                            eval      wwReqChain = CRLF

        c                   eval      rc = SendReq( peComm

        c                                         :
   %addr(wwReqChain)+VARPREF

        c                                         : %len(wwReqChain)

        c                                         : peTimeout )

        c                   if        rc < 1

        c                   return    rc

        c                   end


   It is returning a -1.  The first call above this code with the full
   request chain seems to work as it is returning the buffer length
   successfully.  Just breaks when it sends CRLF.

   Looking at the documentation on the send() api that this ultimately
   drills down to kind of tells me that most of the errors get mapped to
   the one (broken pipe) I am receiving.  So I was wondering if anyone
   else has experienced this and can help me out.  Here's my debug log:


   HTTPAPI Ver 1.24 released 2012-01-23

   OS/400 Ver V5R4M0


   New iconv() objects set, PostRem=819. PostLoc=0. ProtRem=819. ProtLoc=0

   http_url_get(): entered

   http_persist_open(): entered

   http_long_ParseURL(): entered

   DNS resolver retrans: 2

   DNS resolver retry  : 2

   DNS resolver options: x'00000136'

   DNS default domain: sxx.xxxxx.com

   DNS server found: 16n.nnn.4n.3

   DNS server found: 17n.1n8.5n.1nn

   DNS server found: 1nn.nn1.nn.1nn

   http_persist_get(): entered

   http_persist_req(GET) entered.

   http_long_ParseURL(): entered

   do_oper(GET): entered

   There are 0 cookies in the cache

   GET /infocenter/iseries/v6r1m0/topic/rzakj/rzakj.pdf HTTP/1.1

   Host: publib.boulder.ibm.com

   User-Agent: http-api/1.24


   SetError() #55: blockwrite: send: Broken pipe.

   http_close(): entered


   Thanks in advance.

   Alan Anderson

   P.S. I x'd and n'd out the IP and domains.
-----------------------------------------------------------------------
This is the FTPAPI mailing list.  To unsubscribe, please go to:
http://www.scottklement.com/mailman/listinfo/ftpapi
-----------------------------------------------------------------------