[SCM] Samba Shared Repository - branch v3-3-test updated -
release-3-2-0pre2-4746-g9aa543f
Stefan Metzmacher
metze at samba.org
Mon Dec 29 11:17:24 GMT 2008
The branch, v3-3-test has been updated
via 9aa543fee7ebcc95125d18868bdec7e4bf577d8a (commit)
from 8c7552790934397c1bbb7e93eb64716a5fed31fa (commit)
http://gitweb.samba.org/?p=samba.git;a=shortlog;h=v3-3-test
- Log -----------------------------------------------------------------
commit 9aa543fee7ebcc95125d18868bdec7e4bf577d8a
Author: Stefan Metzmacher <metze at samba.org>
Date: Wed Dec 17 17:16:50 2008 +0100
s3:dbwrap: fix dbwrap_store_uint32() to match dbwrap_store_int32()
All callers expect 0 an success and -1 on error.
metze
(cherry picked from commit a255f9ce713b29552722ec73e4038226959e1c8e)
-----------------------------------------------------------------------
Summary of changes:
source/include/proto.h | 2 +-
source/lib/dbwrap_util.c | 4 ++--
2 files changed, 3 insertions(+), 3 deletions(-)
Changeset truncated at 500 lines:
diff --git a/source/include/proto.h b/source/include/proto.h
index db47e2f..cc8e740 100644
--- a/source/include/proto.h
+++ b/source/include/proto.h
@@ -460,7 +460,7 @@ int32_t dbwrap_fetch_int32(struct db_context *db, const char *keystr);
int dbwrap_store_int32(struct db_context *db, const char *keystr, int32_t v);
bool dbwrap_fetch_uint32(struct db_context *db, const char *keystr,
uint32_t *val);
-bool dbwrap_store_uint32(struct db_context *db, const char *keystr, uint32_t v);
+int dbwrap_store_uint32(struct db_context *db, const char *keystr, uint32_t v);
uint32_t dbwrap_change_uint32_atomic(struct db_context *db, const char *keystr,
uint32_t *oldval, uint32_t change_val);
int32 dbwrap_change_int32_atomic(struct db_context *db, const char *keystr,
diff --git a/source/lib/dbwrap_util.c b/source/lib/dbwrap_util.c
index ddc6131..3be3a49 100644
--- a/source/lib/dbwrap_util.c
+++ b/source/lib/dbwrap_util.c
@@ -78,7 +78,7 @@ bool dbwrap_fetch_uint32(struct db_context *db, const char *keystr,
return true;
}
-bool dbwrap_store_uint32(struct db_context *db, const char *keystr, uint32_t v)
+int dbwrap_store_uint32(struct db_context *db, const char *keystr, uint32_t v)
{
struct db_record *rec;
uint32 v_store;
@@ -86,7 +86,7 @@ bool dbwrap_store_uint32(struct db_context *db, const char *keystr, uint32_t v)
rec = db->fetch_locked(db, NULL, string_term_tdb_data(keystr));
if (rec == NULL) {
- return false;
+ return -1;
}
SIVAL(&v_store, 0, v);
--
Samba Shared Repository
More information about the samba-cvs
mailing list