Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

version: fix shadowing a libssh.h symbol #14617

Closed
wants to merge 1 commit into from

Conversation

vszakats
Copy link
Member

/Users/runner/work/curl/curl/lib/version.c: In function 'curl_version_info':
/Users/runner/work/curl/curl/lib/version.c:584:15: error: declaration of 'ssh_buffer' shadows a global declaration [-Werror=shadow]
  584 |   static char ssh_buffer[80];
      |               ^~~~~~~~~~
In file included from /Users/runner/work/curl/curl/lib/vssh/ssh.h:35,
                 from /Users/runner/work/curl/curl/lib/urldata.h:185,
                 from /Users/runner/work/curl/curl/lib/altsvc.c:32,
                 from /Users/runner/work/curl/curl/bld/lib/CMakeFiles/libcurl_shared.dir/Unity/unity_0_c.c:4:
/opt/homebrew/include/libssh/libssh.h:99:35: note: shadowed declaration is here
   99 | typedef struct ssh_buffer_struct* ssh_buffer;
      |                                   ^~~~~~~~~~

Ref: https://github.com/curl/curl/actions/runs/10477958747/job/29020250670#step:9:48

Tested via #14614

```
/Users/runner/work/curl/curl/lib/version.c: In function 'curl_version_info':
/Users/runner/work/curl/curl/lib/version.c:584:15: error: declaration of 'ssh_buffer' shadows a global declaration [-Werror=shadow]
  584 |   static char ssh_buffer[80];
      |               ^~~~~~~~~~
In file included from /Users/runner/work/curl/curl/lib/vssh/ssh.h:35,
                 from /Users/runner/work/curl/curl/lib/urldata.h:185,
                 from /Users/runner/work/curl/curl/lib/altsvc.c:32,
                 from /Users/runner/work/curl/curl/bld/lib/CMakeFiles/libcurl_shared.dir/Unity/unity_0_c.c:4:
/opt/homebrew/include/libssh/libssh.h:99:35: note: shadowed declaration is here
   99 | typedef struct ssh_buffer_struct* ssh_buffer;
      |                                   ^~~~~~~~~~
```
Ref: https://github.com/curl/curl/actions/runs/10477958747/job/29020250670#step:9:48

Tested via curl#14614
@vszakats vszakats closed this in 2e88ef1 Aug 20, 2024
@vszakats vszakats deleted the cm-libssh-fix-shadow-var branch August 20, 2024 21:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Development

Successfully merging this pull request may close these issues.

2 participants