Skip to content

x/net/spdy: EOF #10540

Closed
Closed
@dvyukov

Description

The following program panics. Should return error.

package main

import (
    "bytes"
    "encoding/hex"
    "golang.org/x/net/spdy"
    "io/ioutil"
)

func main() {
    data, _ := hex.DecodeString("30303030")
    framer, err := spdy.NewFramer(ioutil.Discard, bytes.NewReader(data))
    if err != nil {
        panic(err)
    }
    for ;; {
        f, err := framer.ReadFrame()
        if err != nil {
            if f != nil {
                panic(err)
            }
            return
        }
        err = framer.WriteFrame(f)
        if err != nil {
            panic(err)
        }
    }
}
panic: EOF

on commit 6f62f426de90c0ed6a55207b51476115fcb17237

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions