bmesh: fixed merge issues with navmesh (though I've not tested if it works yet).
[blender.git] / source / blender / bmesh / operators / connectops.c
index 1e7dbc3f08c68de34f4bdb3e56f77b3306933783..302d9b805b144b27cc7c1cbc4e5e7be20997b018 100644 (file)
@@ -352,7 +352,7 @@ void bmesh_bridge_loops_exec(BMesh *bm, BMOperator *op)
                if (wdir == 0) {
                        for (i=0; i<BLI_array_count(ee1); i++) {
                                j = CLAMP_INDEX((i*dir1)+starti, lenv1);
-                               if (ee1[j]->l) {
+                               if (ee1[j]->l && ee2[j]->l) {
                                        wdir = (ee2[j]->l->v == vv2[j]) ? (1) : (-1);
                                        break;
                                }