Thanks, it works fine but in order to make app working I have added SysTaskDelay next to last NetLibSend:

    SysTaskDelay (SysTicksPerSecond ());

if (NetLibSocketShutdown (netLib, dataSocket, netSocketDirBoth, -1, &err) != 0) printf ("Cannot shut connection down.\n");

if (ExNetLibSocketClose (netLib, dataSocket, -1, &err) != 0) printf ("Cannot close data connection.\n");
else printf ("Data connection closed.\n");


Additional delay causes significant degradation of transfer rate. Is there another way how to solve this issue? I also try to reduce number of ticks delayed but with lower number of ticks connection lost portion of data sent to server.

Petr

Chris Faherty wrote:
On Wednesday 02 June 2004 09:42 am, Petr Stetina wrote:


What should I change in my app to overcome this problem?


    NetSocketLingerType linger;

    linger.onOff = true;
    linger.time = 0;
    NetLibSocketOptionSet(AppNetRefnum, sock, netSocketOptLevelSocket,
        netSocketOptSockLinger, &linger, sizeof(linger), AppNetTimeout,
        &errno);

That should help.  I remember running into that issue before.



--
For information on using the Palm Developer Forums, or to unsubscribe, please see 
http://www.palmos.com/dev/support/forums/

Reply via email to