I'm sending the last wave of patches cleaning dead assignments or fixing code
around them.
0001-Dead-assignments-cleanup-in-providers-code.patch:
Here the biggest change is in prototype of sdap_access_decide_offline, which IMO
doesn't need to return any value, since it returns alway EOK now and there is
no code which could be failing.
0002-Dead-assignments-cleanup-in-NSS-responder.patch
0003-Dead-assignments-cleanup-in-memberof-module.patch:
Here I'm not entirely sure about return code LDB_ERR_OPERATIONS_ERROR. The
variable ret can contain either 0 or -1 (in case of insufficient memory, I
checked the ldb code). I think returning -1 further isn't the right choice,
thus either ENOMEM or LDB_ERR_OPERATIONS_ERR seem to be acceptable. I chose
the latter one, because it indicates generic ldb error. ENOMEM could be
convenient now, but in the future the behavior of ldb_schema_attribute_add
might change and ENOMEM would become misleading.
0004-Dead-assignments-cleanup-in-various-places-in-SSSD.patch
The last hunk should be fixing this:
http://jhrozek.fedorapeople.org/sssd-
clang-llvm/report-G4QCn7.html#EndPath . IMO the original code had a flaw there,
which would make the inner while cycle useless in case write() actually wrote
less bytes than it could. This way it should be fixed.
--
Jan