[SCM] Samba Shared Repository - branch master updated - 2a76f4d8c832155253be971975b0ac50649c7515

Derrell Lipman derrell at samba.org
Fri Oct 24 14:32:21 GMT 2008


The branch, master has been updated
       via  2a76f4d8c832155253be971975b0ac50649c7515 (commit)
      from  f7692d16e3dc5e580364852c709c6c4a371dd32e (commit)

http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master


- Log -----------------------------------------------------------------
commit 2a76f4d8c832155253be971975b0ac50649c7515
Author: Derrell Lipman <derrell.lipman at unwireduniverse.com>
Date:   Fri Oct 24 10:26:56 2008 -0400

    Error return is False, not -1
    
    - There were a few places in SMBC_getatr() that returned -1 instead of a
      boolean.  -1 was intended to mean error, but that's what False is for, and
      the usages of this function assume that it returns a boolean with False as
      the error condition.
    
    Derrell

-----------------------------------------------------------------------

Summary of changes:
 source3/libsmb/libsmb_file.c |    6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)


Changeset truncated at 500 lines:

diff --git a/source3/libsmb/libsmb_file.c b/source3/libsmb/libsmb_file.c
index 7b28709..ece056d 100644
--- a/source3/libsmb/libsmb_file.c
+++ b/source3/libsmb/libsmb_file.c
@@ -518,7 +518,7 @@ SMBC_getatr(SMBCCTX * context,
                 
 		errno = EINVAL;
 		TALLOC_FREE(frame);
- 		return -1;
+ 		return False;
  	}
         
 	/* path fixup for . and .. */
@@ -527,14 +527,14 @@ SMBC_getatr(SMBCCTX * context,
 		if (!fixedpath) {
 			errno = ENOMEM;
 			TALLOC_FREE(frame);
-			return -1;
+			return False;
 		}
 	} else {
 		fixedpath = talloc_strdup(frame, path);
 		if (!fixedpath) {
 			errno = ENOMEM;
 			TALLOC_FREE(frame);
-			return -1;
+			return False;
 		}
 		trim_string(fixedpath, NULL, "\\..");
 		trim_string(fixedpath, NULL, "\\.");


-- 
Samba Shared Repository


More information about the samba-cvs mailing list