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

Multipart file upload throws with special characters in filename #687

Closed
brezinajn opened this issue Oct 31, 2018 · 1 comment
Closed

Multipart file upload throws with special characters in filename #687

brezinajn opened this issue Oct 31, 2018 · 1 comment
Assignees

Comments

@brezinajn
Copy link

When I try to upload file with special characters in filename I get exception.
io.ktor.http.cio.ParserException: No HTTP header value provided for name ?ti.jpg": ?ti.jpg"
Problematic characters are ě, š, č, ř, ž but I presume there are more.

Code sample

private suspend fun PipelineContext<Unit, ApplicationCall>.getFile(): File {
        val multipart = call.receiveMultipart()
        var resultFile: File? = null

        multipart.forEachPart {
            ...
        }

Crashes on forEachPart line.

@cy6erGn0m
Copy link
Contributor

Fixed in 1.0.1

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants