Skip to content

Commit

Permalink
Remove redundant assignments to ftp->data
Browse files Browse the repository at this point in the history
ftp_getdata() already does this.

Closes GH-12849.
  • Loading branch information
nielsdos committed Dec 2, 2023
1 parent 35cf7ab commit f3cddbb
Showing 1 changed file with 0 additions and 3 deletions.
3 changes: 0 additions & 3 deletions ext/ftp/ftp.c
Original file line number Diff line number Diff line change
Expand Up @@ -898,8 +898,6 @@ ftp_get(ftpbuf_t *ftp, php_stream *outstream, const char *path, const size_t pat
goto bail;
}

ftp->data = data;

if (resumepos > 0) {
int arg_len = snprintf(arg, sizeof(arg), ZEND_LONG_FMT, resumepos);

Expand Down Expand Up @@ -993,7 +991,6 @@ ftp_put(ftpbuf_t *ftp, const char *path, const size_t path_len, php_stream *inst
if ((data = ftp_getdata(ftp)) == NULL) {
goto bail;
}
ftp->data = data;

if (startpos > 0) {
int arg_len = snprintf(arg, sizeof(arg), ZEND_LONG_FMT, startpos);
Expand Down

0 comments on commit f3cddbb

Please sign in to comment.