Cleanup: remove unnecessary branch when lib linking constraints

Differential Revision: https://developer.blender.org/D7386

Reviewers: mont29
This commit is contained in:
Jacques Lucke 2020-04-14 11:50:36 +02:00
parent 6e272b9ba4
commit b07e8a24f5
1 changed files with 2 additions and 11 deletions

View File

@ -3834,20 +3834,11 @@ typedef struct tConstraintLinkData {
/* callback function used to relink constraint ID-links */
static void lib_link_constraint_cb(bConstraint *UNUSED(con),
ID **idpoin,
bool is_reference,
bool UNUSED(is_reference),
void *userdata)
{
tConstraintLinkData *cld = (tConstraintLinkData *)userdata;
/* for reference types, we need to increment the user-counts on load... */
if (is_reference) {
/* reference type - with usercount */
*idpoin = newlibadr(cld->fd, cld->id->lib, *idpoin);
}
else {
/* target type - no usercount needed */
*idpoin = newlibadr(cld->fd, cld->id->lib, *idpoin);
}
*idpoin = newlibadr(cld->fd, cld->id->lib, *idpoin);
}
static void lib_link_constraints(FileData *fd, ID *id, ListBase *conlist)