×

Discussion Board

Results 1 to 5 of 5
  1. #1
    Regular Contributor
    Join Date
    Feb 2008
    Posts
    252

    Exclamation socket::send same request through one session

    Hi all,

    I am facing a pb . I have established a connection sucessfully with a server . Then i want to request some data repeatedly. It works perfectly fine. But my pb here is when i get complete data of a request i need to resend the same request and again get the response. But here i get KErrEof (that may be right indication).
    But here i Have made same request again cancelling prev request as below
    Code:
    case KErrEof:
         WriteDataToFile();
         iBuffer.Zero();
         m_sData.Zero();
         iSocket.CancelWrite();
         IssueRead();
          break;
    But every time i get the same error can any one help me to solve this pb...

    Thanks

  2. #2
    Nokia Developer Moderator
    Join Date
    Feb 2006
    Location
    Oslo, Norway
    Posts
    28,684

    Re: socket::send same request through one session

    If the "initial" KErrEof in the "case" comes from a the socket, it probably means that the socket is closed by the other party. And in that case it will not get re-opened just because you issue a CancelWrite then an IssueRead (by the way: can you see some kind of contradiction with the bold words?)

  3. #3
    Super Contributor
    Join Date
    Jul 2007
    Location
    ShenZhen, China
    Posts
    4,346

    Re: socket::send same request through one session

    like wizard said, it also maybe server close your connection.
    Last edited by qxiaoyuan; 2008-11-19 at 02:15.
    ----------------------------
    坚持学习, 坚持编码
    http://www.devdiv.net/
    qxiaoyuan

  4. #4
    Regular Contributor
    Join Date
    Feb 2008
    Posts
    252

    Re: socket::send same request through one session

    Then Does it mean that i cann't send same request again and get the response again within a session.

    How Can i make it.....


    Thanks

  5. #5
    Super Contributor
    Join Date
    Jul 2007
    Location
    ShenZhen, China
    Posts
    4,346

    Re: socket::send same request through one session

    Quote Originally Posted by deepakk View Post
    Then Does it mean that i cann't send same request again and get the response again within a session.

    How Can i make it.....


    Thanks
    no, it judge by your net protocol.

    it seem that your server shutdown the connection after send response data. like http 1.0 protocol.
    ----------------------------
    坚持学习, 坚持编码
    http://www.devdiv.net/
    qxiaoyuan

Similar Threads

  1. SIR (Session Initiation Request)
    By Stradivari in forum Smart Messaging
    Replies: 0
    Last Post: 2007-05-15, 15:38
  2. HTTP Request Pipelining
    By shashishaw in forum Symbian Networking & Messaging (Closed)
    Replies: 2
    Last Post: 2006-08-25, 16:24
  3. How can i solve this error?
    By symbian-newbie in forum Symbian
    Replies: 6
    Last Post: 2006-05-23, 05:33
  4. SIP content type
    By hlothman in forum Symbian Networking & Messaging (Closed)
    Replies: 8
    Last Post: 2006-05-17, 09:26
  5. session has been lost in HttpRequest ?
    By garyshi in forum Mobile Java General
    Replies: 0
    Last Post: 2003-07-08, 17:45

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
×