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

curl -JO [hostname] with no Content-Disposition header fails #14939

Closed
bagder opened this issue Sep 16, 2024 · 0 comments
Closed

curl -JO [hostname] with no Content-Disposition header fails #14939

bagder opened this issue Sep 16, 2024 · 0 comments

Comments

@bagder
Copy link
Member

bagder commented Sep 16, 2024

(Originally reported here by @BrianInglis)

I did this

$ curl -JO curl.se
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
Warning: Remote filename has no length

I expected the following

The same as curl -O curl.se does:

Warning: No remote file name, uses "curl_response"

curl/libcurl version

8.10.0 / git commit 41290d4

operating system

Linux, but hardly matters.

bagder added a commit that referenced this issue Sep 17, 2024
Use the same fallback as for regular -O

Reported-by: Brian Inglis
Fixes #14939
bagder added a commit that referenced this issue Sep 17, 2024
Use the same fallback for content-disposition cases as for regular -O

Reported-by: Brian Inglis
Fixes #14939
Closes #14940
@bagder bagder closed this as completed in 0cfc7fc Sep 17, 2024
moritzbuhl pushed a commit to moritzbuhl/curl that referenced this issue Sep 19, 2024
Use the same fallback for content-disposition cases as for regular -O

Add test692: verify -JO with URL without a file name

Reported-by: Brian Inglis
Fixes curl#14939
Closes curl#14940
moritzbuhl pushed a commit to moritzbuhl/curl that referenced this issue Sep 19, 2024
Use the same fallback for content-disposition cases as for regular -O

Add test692: verify -JO with URL without a file name

Reported-by: Brian Inglis
Fixes curl#14939
Closes curl#14940
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Development

Successfully merging a pull request may close this issue.

1 participant