SSVAL(outbuf,smb_pid,pid);
SSVAL(outbuf,smb_uid,uid);
SSVAL(outbuf,smb_mid,mid);
- if (Protocol > PROTOCOL_CORE)
+ if (Protocol > PROTOCOL_COREPLUS)
{
SCVAL(outbuf,smb_flg,0x8);
SSVAL(outbuf,smb_flg2,0x1);
strcpy(pword, ""); passlen=1;
}
- if (Protocol <= PROTOCOL_CORE) {
+ if (Protocol <= PROTOCOL_COREPLUS) {
set_message(outbuf,0,6 + strlen(service) + passlen + strlen(dev),True);
CVAL(outbuf,smb_com) = SMBtcon;
setup_pkt(outbuf);
}
- if (Protocol <= PROTOCOL_CORE) {
+ if (Protocol <= PROTOCOL_COREPLUS) {
max_xmit = SVAL(inbuf,smb_vwv0);
cnum = SVAL(inbuf,smb_vwv1);
return -1;
}
+#ifdef EISCONN
+ if (ret < 0 && errno == EISCONN) {
+ errno = 0;
+ ret = 0;
+ }
+#endif
+
if (ret < 0) {
DEBUG(2,("error connecting to %s:%d (%s)\n",
inet_ntoa(*addr),port,strerror(errno)));