mirror of
https://github.com/samba-team/samba.git
synced 2025-11-25 00:23:52 +03:00
r14431: don't call qsort with a null array
This commit is contained in:
committed by
Gerald (Jerry) Carter
parent
b607be9cda
commit
2c33f577ad
@@ -241,7 +241,9 @@ static int ltdb_index_dn_simple(struct ldb_module *module,
|
||||
|
||||
talloc_free(msg);
|
||||
|
||||
qsort(list->dn, list->count, sizeof(char *), (comparison_fn_t) list_cmp);
|
||||
if (list->count > 1) {
|
||||
qsort(list->dn, list->count, sizeof(char *), (comparison_fn_t) list_cmp);
|
||||
}
|
||||
|
||||
return 1;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user