• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

TykTechnologies / tyk / 6648
62%
master: %

Build:
Build:
LAST BUILD BRANCH: v2.9.4.8
DEFAULT BRANCH: master
Ran 20 May 2019 05:34PM UTC
Jobs 1
Files 106
Run time 7s
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

pending completion
6648

push

travis-ci

buger
res_handler_transform: make sure bodyData is available on XML errors (#2133)

For #2016.

I was able to reproduce using the instructions described in the ticket. The issue occurs at this point:

```go
	bodyData := make(map[string]interface{})
	switch tmeta.TemplateData.Input {
	case apidef.RequestXML:
		if len(body) == 0 {
			body = []byte("<_/>")
		}

		mxj.XmlCharsetReader = WrappedCharsetReader
		var err error

		bodyData, err := mxj.NewMapXml(body)
		if err != nil {
			logger.WithError(err).Error("Error unmarshalling XML")
		}
```

When `mxj.NewMapXml` returns an error, `bodyData` is not properly set and further references to it fail (like setting context vars using `bodyData["_tyk_context"] = ctxGetData(req)`).

This approach avoids replacing `bodyData`.

10552 of 16926 relevant lines covered (62.34%)

0.7 hits per line

Jobs
ID Job ID Ran Files Coverage
1 6648.1 (LATEST_GO=true) 20 May 2019 05:34PM UTC 0
62.34
Travis Job 6648.1
Source Files on build 6648
Detailed source file information is not available for this build.
  • Back to Repo
  • Travis Build #6648
  • ba758461 on github
  • Prev Build on release-2.8 (#6644)
  • Next Build on release-2.8 (#6649)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc