git.samba.org
/
obnox
/
samba
/
samba-obnox.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
1a0e61e
)
idmap_autorid: add parameter checks to idmap_autorid_saveconfig()
author
Atul Kulkarni
<atul.kulkarni@in.ibm.com>
Wed, 28 Aug 2013 15:00:56 +0000
(17:00 +0200)
committer
Michael Adam
<obnox@samba.org>
Tue, 1 Oct 2013 08:49:12 +0000
(10:49 +0200)
Signed-off-by: Atul Kulkarni <atul.kulkarni@in.ibm.com>
Reviewed-by: Michael Adam <obnox@samba.org>
source3/winbindd/idmap_autorid_tdb.c
patch
|
blob
|
history
diff --git
a/source3/winbindd/idmap_autorid_tdb.c
b/source3/winbindd/idmap_autorid_tdb.c
index 62b6d32f3bbfb46c59ca7d736b13f9e371a24e35..825e8fcd632038e1f63f8dd01d47e5a1520d478b 100644
(file)
--- a/
source3/winbindd/idmap_autorid_tdb.c
+++ b/
source3/winbindd/idmap_autorid_tdb.c
@@
-414,10
+414,14
@@
NTSTATUS idmap_autorid_saveconfig(struct db_context *db,
struct autorid_global_config *cfg)
{
- NTSTATUS status;
+ NTSTATUS status
= NT_STATUS_INVALID_PARAMETER
;
TDB_DATA data;
char *cfgstr;
+ if (db == NULL || cfg == NULL) {
+ goto done;
+ }
+
cfgstr =
talloc_asprintf(talloc_tos(),
"minvalue:%u rangesize:%u maxranges:%u",
@@
-433,5
+437,6
@@
NTSTATUS idmap_autorid_saveconfig(struct db_context *db,
talloc_free(cfgstr);
+done:
return status;
}