oops!

1)  I'm actually using the Emulator (not the simulator).
2)  The net config I retrieve is: netCfgNameDefault
3)  I perform following setting on an opened socket:
        NetLibSocketOptionSet(NetLibRefNum, SockH, netSocketOptLevelSocket, 
netSocketOptSockRcvTimeout, &SockTimeout, sizeof(SockTimeout), 
120*sysTicksPerSecond, &err);
        NetLibSocketOptionSet(NetLibRefNum, SockH, netSocketOptLevelSocket, 
netSocketOptSockRcvBufSize, &downloadSize, sizeof(downloadSize), 
120*sysTicksPerSecond, &err);
4)  I changed the custom URL I was using earlier to http://www.yahoo.com and I 
get past the NetLibGetHostByName issue (so I guess the DNS was setup - somehow 
;-).  

NOW I GET A netErrParamErr.  Here is the code to the SocketConnect:

        NetSocketAddrINType hAddress;
        hAddress.family = netSocketAddrINET;
        hAddress.port = NetHToNS(80);
        hAddress.addr = hostInfoBuf.address[1];
        if (NetLibSocketConnect(NetLibRefNum, SockH, (NetSocketAddrType*) 
&hAddress, sizeof(hAddress), SockTimeout, &err) != 0)
                goto Exit;

Oh! lest your body shakes involuntarily on seeing the goto, PLEASE -- I 
inherited this code ;-)

hAddress in the connect statement looks ok in the debugger... although I don't 
know how to convert the UInt32 IP Address to a dotted decimal.

ANY POINTERS on how to resolve the netErrParamErr ??  I'll keep trying stuff in 
the mean time.

SM



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

Reply via email to