svn commit: samba r23943 - in branches/SAMBA_3_2/source/libads: .
metze at samba.org
metze at samba.org
Wed Jul 18 07:30:47 GMT 2007
Author: metze
Date: 2007-07-18 07:30:41 +0000 (Wed, 18 Jul 2007)
New Revision: 23943
WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=23943
Log:
- always provide ads_setup_sasl_wrapping() function
- read/write returning 0 means EOF and we need to return direct
metze
Modified:
branches/SAMBA_3_2/source/libads/sasl_wrapping.c
Changeset:
Modified: branches/SAMBA_3_2/source/libads/sasl_wrapping.c
===================================================================
--- branches/SAMBA_3_2/source/libads/sasl_wrapping.c 2007-07-18 01:27:03 UTC (rev 23942)
+++ branches/SAMBA_3_2/source/libads/sasl_wrapping.c 2007-07-18 07:30:41 UTC (rev 23943)
@@ -93,7 +93,7 @@
ret = LBER_SBIOD_READ_NEXT(sbiod,
ads->ldap.in.buf + ads->ldap.in.ofs,
4 - ads->ldap.in.ofs);
- if (ret < 0) return ret;
+ if (ret <= 0) return ret;
ads->ldap.in.ofs += ret;
if (ads->ldap.in.ofs < 4) goto eagain;
@@ -120,7 +120,7 @@
ret = LBER_SBIOD_READ_NEXT(sbiod,
ads->ldap.in.buf + ads->ldap.in.ofs,
ads->ldap.in.needed);
- if (ret < 0) return ret;
+ if (ret <= 0) return ret;
ads->ldap.in.ofs += ret;
ads->ldap.in.needed -= ret;
@@ -227,7 +227,7 @@
ret = LBER_SBIOD_WRITE_NEXT(sbiod,
ads->ldap.out.buf + ads->ldap.out.ofs,
ads->ldap.out.left);
- if (ret < 0) return ret;
+ if (ret <= 0) return ret;
ads->ldap.out.ofs += ret;
ads->ldap.out.left -= ret;
@@ -302,5 +302,11 @@
return ADS_SUCCESS;
}
-
+#else
+ADS_STATUS ads_setup_sasl_wrapping(ADS_STRUCT *ads,
+ const struct ads_saslwrap_ops *ops,
+ void *private_data)
+{
+ return ADS_ERROR_NT(NT_STATUS_NOT_SUPPORTED);
+}
#endif /* HAVE_LDAP_SASL_WRAPPING */
More information about the samba-cvs
mailing list