mirror of
https://github.com/upa/mscp.git
synced 2026-05-18 01:57:29 +08:00
fix: use off_t for lseek
This commit is contained in:
@@ -278,9 +278,9 @@ void mscp_close(mf *f)
|
|||||||
free(f);
|
free(f);
|
||||||
}
|
}
|
||||||
|
|
||||||
int mscp_lseek(mf *f, size_t off)
|
off_t mscp_lseek(mf *f, off_t off)
|
||||||
{
|
{
|
||||||
int ret;
|
off_t ret;
|
||||||
|
|
||||||
if (f->remote) {
|
if (f->remote) {
|
||||||
ret = sftp_seek64(f->remote, off);
|
ret = sftp_seek64(f->remote, off);
|
||||||
|
|||||||
@@ -45,7 +45,7 @@ typedef struct mf_struct mf;
|
|||||||
|
|
||||||
mf *mscp_open(const char *path, int flags, mode_t mode, sftp_session sftp);
|
mf *mscp_open(const char *path, int flags, mode_t mode, sftp_session sftp);
|
||||||
void mscp_close(mf *f);
|
void mscp_close(mf *f);
|
||||||
int mscp_lseek(mf *f, size_t off);
|
off_t mscp_lseek(mf *f, off_t off);
|
||||||
|
|
||||||
/* mscp_setstat() involves chmod and truncate. It executes both at
|
/* mscp_setstat() involves chmod and truncate. It executes both at
|
||||||
* once via a single SFTP command (sftp_setstat()).
|
* once via a single SFTP command (sftp_setstat()).
|
||||||
|
|||||||
Reference in New Issue
Block a user