Skip to content

Commit

Permalink
vine: when copying mounts, do not clone input file twice. (#3614)
Browse files Browse the repository at this point in the history
  • Loading branch information
btovar authored Jan 25, 2024
1 parent 9b74503 commit 9e817d9
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions taskvine/src/manager/vine_mount.c
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ struct vine_mount *vine_mount_create(
m->remote_name = 0;
}
m->flags = flags;
m->substitute = substitute;
m->substitute = vine_file_clone(substitute);

return m;
}
Expand All @@ -44,5 +44,5 @@ struct vine_mount *vine_mount_copy(struct vine_mount *m)
{
if (!m)
return 0;
return vine_mount_create(vine_file_clone(m->file), m->remote_name, m->flags, vine_file_clone(m->substitute));
return vine_mount_create(m->file, m->remote_name, m->flags, m->substitute);
}

0 comments on commit 9e817d9

Please sign in to comment.