Преглед изворни кода

[c] Fixed sorting of path constraints when slot attachment is null.

badlogic пре 8 година
родитељ
комит
9f569fef3b
1 измењених фајлова са 1 додато и 1 уклоњено
  1. 1 1
      spine-c/spine-c/src/spine/Skeleton.c

+ 1 - 1
spine-c/spine-c/src/spine/Skeleton.c

@@ -269,7 +269,7 @@ static void _sortPathConstraint(_spSkeleton* const internal, spPathConstraint* c
 		_sortPathConstraintAttachment(internal, skeleton->data->skins[i], slotIndex, slotBone);
 
 	attachment = slot->attachment;
-	if (attachment->type == SP_ATTACHMENT_PATH) _sortPathConstraintAttachmentBones(internal, attachment, slotBone);
+	if (attachment && attachment->type == SP_ATTACHMENT_PATH) _sortPathConstraintAttachmentBones(internal, attachment, slotBone);
 
 	constrained = constraint->bones;
 	boneCount = constraint->bonesCount;