Skip to content

ReadAll function failed to read  #9

@AlessandroZ

Description

@AlessandroZ

Hi @tomnomnom,

This issue could be related to #5.

I had some timeout problems using your tool so I tried to investigate a bit to fix it. Fixing the timeout to 5s didn't resolve my problem (with req.Timeout = time.Second * 5). However, I have seen that the timeout wasn't the problem but the hang came from the ReadAll function. When its passed here and it arrives here.

Even reading byte by byte the problem occured:

} else {

	for {
		v, err := r.ReadByte()
		if v == 0 || err != nil {
			break
		}
        resp.body = append(resp.body, v)
    }
}

I try to manage to check the size before reading the buffer but without success. Right now, I have removed the else condition to be sure it does not hang out.

Thanks again for all your tools, your doing an amazing work.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions