svn commit: samba r22636 - in branches/SAMBA_3_0/source/nsswitch: .
gd at samba.org
gd at samba.org
Wed May 2 15:44:06 GMT 2007
Author: gd
Date: 2007-05-02 15:44:05 +0000 (Wed, 02 May 2007)
New Revision: 22636
WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=22636
Log:
Fix logic bug.
We certainly don't want to crash winbind on each sucessfull
centry_uint{8,16,32,64} read.
Jeremy, please check :-)
Guenther
Modified:
branches/SAMBA_3_0/source/nsswitch/winbindd_cache.c
Changeset:
Modified: branches/SAMBA_3_0/source/nsswitch/winbindd_cache.c
===================================================================
--- branches/SAMBA_3_0/source/nsswitch/winbindd_cache.c 2007-05-02 09:54:06 UTC (rev 22635)
+++ branches/SAMBA_3_0/source/nsswitch/winbindd_cache.c 2007-05-02 15:44:05 UTC (rev 22636)
@@ -221,7 +221,7 @@
{
uint32 ret;
- if (centry_check_bytes(centry, 4)) {
+ if (!centry_check_bytes(centry, 4)) {
smb_panic_fn("centry_uint32");
return (uint32)-1;
}
@@ -236,7 +236,7 @@
static uint16 centry_uint16(struct cache_entry *centry)
{
uint16 ret;
- if (centry_check_bytes(centry, 2)) {
+ if (!centry_check_bytes(centry, 2)) {
smb_panic_fn("centry_uint16");
return (uint16)-1;
}
@@ -251,7 +251,7 @@
static uint8 centry_uint8(struct cache_entry *centry)
{
uint8 ret;
- if (centry_check_bytes(centry, 1)) {
+ if (!centry_check_bytes(centry, 1)) {
smb_panic_fn("centry_uint8");
return (uint8)-1;
}
@@ -266,7 +266,7 @@
static NTTIME centry_nttime(struct cache_entry *centry)
{
NTTIME ret;
- if (centry_check_bytes(centry, 8)) {
+ if (!centry_check_bytes(centry, 8)) {
smb_panic_fn("centry_nttime");
return (NTTIME)-1;
}
@@ -300,7 +300,7 @@
return NULL;
}
- if (centry_check_bytes(centry, (size_t)len)) {
+ if (!centry_check_bytes(centry, (size_t)len)) {
smb_panic_fn("centry_string");
return NULL;
}
@@ -332,7 +332,7 @@
return NULL;
}
- if (centry_check_bytes(centry, 16)) {
+ if (!centry_check_bytes(centry, 16)) {
return NULL;
}
More information about the samba-cvs
mailing list