Skip to content

Commit 7341b40

Browse files
lundmanbehlendorf
authored andcommitted
Remove old orig_fd variable from zfs send
Possibly required in the past, but is currently fills no purpose. Ordinarily such tiny cleanup is not generally worth it, however on the macOS port, in a future commit, we do unspeakable things to the "fd" for send/recv, and it would be easier to only have to deal with one "fd" instead of two. Reviewed-by: Brian Behlendorf <[email protected]> Reviewed-by: Tony Nguyen <[email protected]> Signed-off-by: Jorgen Lundman <[email protected]> Closes #12404
1 parent fa9b588 commit 7341b40

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

lib/libzfs/libzfs_sendrecv.c

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2403,7 +2403,6 @@ zfs_send_one(zfs_handle_t *zhp, const char *from, int fd, sendflags_t *flags,
24032403
int err;
24042404
libzfs_handle_t *hdl = zhp->zfs_hdl;
24052405
char *name = zhp->zfs_name;
2406-
int orig_fd = fd;
24072406
pthread_t ptid;
24082407
progress_arg_t pa = { 0 };
24092408

@@ -2535,7 +2534,7 @@ zfs_send_one(zfs_handle_t *zhp, const char *from, int fd, sendflags_t *flags,
25352534

25362535
if (flags->props || flags->holds || flags->backup) {
25372536
/* Write the final end record. */
2538-
err = send_conclusion_record(orig_fd, NULL);
2537+
err = send_conclusion_record(fd, NULL);
25392538
if (err != 0)
25402539
return (zfs_standard_error(hdl, err, errbuf));
25412540
}

0 commit comments

Comments
 (0)