1
0
mirror of https://github.com/samba-team/samba.git synced 2025-01-13 13:18:06 +03:00

r19486: Probably Coverity is wrong here, but this fixes their ID 317. Not sure whether

to merge it to 4_0. I want it in 3_0 because it took a bit to persuade myself
that el can not be NULL here.

Volker
This commit is contained in:
Volker Lendecke 2006-10-24 20:20:39 +00:00 committed by Gerald (Jerry) Carter
parent d9f1697c1f
commit c0c035b1c8

View File

@ -209,7 +209,9 @@ int ldb_msg_add_steal_value(struct ldb_message *msg,
ret = ldb_msg_add_value(msg, attr_name, val);
if (ret == LDB_SUCCESS) {
struct ldb_message_element *el;
el = ldb_msg_find_element(msg, attr_name);
if (!(el = ldb_msg_find_element(msg, attr_name))) {
return LDB_ERR_OPERATIONS_ERROR;
}
talloc_steal(el->values, val->data);
}
return ret;