Skip to content

scp: fix missing cast for targets without large file support - #1060

Closed
vszakats wants to merge 1 commit into
libssh2:masterfrom
vszakats:scp-32bit-cast
Closed

vszakats wants to merge 1 commit into
libssh2:masterfrom
vszakats:scp-32bit-cast

Conversation

@vszakats

@vszakats vszakats commented May 30, 2023 •

Copy link
Copy Markdown
Member

E.g. on 32-bit Linux. Issue revealed after adding i386 Linux CI build
in abdf40c #1057.

/home/runner/work/libssh2/libssh2/src/scp.c: In function 'scp_recv':
/home/runner/work/libssh2/libssh2/src/scp.c:765:23: error: conversion from 'libssh2_int64_t' {aka 'long long int'} to '__off_t' {aka 'long int'} may change value [-Werror=conversion]
  765 |         sb->st_size = session->scpRecv_size;
      |                       ^~~~~~~

Ref: https://github.com/libssh2/libssh2/actions/runs/5126803482/jobs/9221746299?pr=1054#step:12:51

Regression from 5db836b #1002
Closes #1060

E.g. on 32-bit Linux.

```
/home/runner/work/libssh2/libssh2/src/scp.c: In function ‘scp_recv’:
/home/runner/work/libssh2/libssh2/src/scp.c:765:23: error: conversion from ‘libssh2_int64_t’ {aka ‘long long int’} to ‘__off_t’ {aka ‘long int’} may change value [-Werror=conversion]
  765 |         sb->st_size = session->scpRecv_size;
      |                       ^~~~~~~
```
Ref: https://github.com/libssh2/libssh2/actions/runs/5126803482/jobs/9221746299?pr=1054#step:12:51

Closes libssh2#1060
@vszakats vszakats added the bug label May 30, 2023
@vszakats vszakats closed this in c317e06 May 31, 2023
@vszakats
vszakats deleted the scp-32bit-cast branch May 31, 2023 02:05
lampmanyao pushed a commit to lampmanyao/libssh2 that referenced this pull request Jul 16, 2023
E.g. on 32-bit Linux. Issue revealed after adding i386 Linux CI build
in abdf40c libssh2#1057.

```
/home/runner/work/libssh2/libssh2/src/scp.c: In function 'scp_recv':
/home/runner/work/libssh2/libssh2/src/scp.c:765:23: error: conversion from 'libssh2_int64_t' {aka 'long long int'} to '__off_t' {aka 'long int'} may change value [-Werror=conversion]
  765 |         sb->st_size = session->scpRecv_size;
      |                       ^~~~~~~
```
Ref: https://github.com/libssh2/libssh2/actions/runs/5126803482/jobs/9221746299?pr=1054#step:12:51

Regression from 5db836b libssh2#1002
Closes libssh2#1060
agreppin pushed a commit to agreppin/libssh2 that referenced this pull request Jul 14, 2024
E.g. on 32-bit Linux. Issue revealed after adding i386 Linux CI build
in abdf40c libssh2#1057.

```
/home/runner/work/libssh2/libssh2/src/scp.c: In function 'scp_recv':
/home/runner/work/libssh2/libssh2/src/scp.c:765:23: error: conversion from 'libssh2_int64_t' {aka 'long long int'} to '__off_t' {aka 'long int'} may change value [-Werror=conversion]
  765 |         sb->st_size = session->scpRecv_size;
      |                       ^~~~~~~
```
Ref: https://github.com/libssh2/libssh2/actions/runs/5126803482/jobs/9221746299?pr=1054#step:12:51

Regression from 5db836b libssh2#1002
Closes libssh2#1060
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant